* { -webkit-tap-highlight-color: transparent; }
::selection { background: #1e40af; color: #fff; }
::-moz-selection { background: #1e40af; color: #fff; }

body { max-width: 100%; height: 100% }
.container.outer { display:block; width: 100%; max-width: 760px; margin: 0 auto; padding: 0 15px }
.container.inner { display:block; width: 100%; max-width: 760px; margin: 0 auto 30px; background: #fff; border-radius: 5px; height: auto; min-height: 500px; padding: 20px }
.htu { background: #fff3cd; color: #333; padding: 15px; border-radius: 5px; margin-top: 30px; margin-bottom: 30px; line-height: 150% }

.lipg-section { border-bottom: 1px solid #e5e5e5; padding-bottom: 20px; margin-bottom: 20px; }
.lipg-section:last-of-type { border-bottom: none; }
.lipg-section h3 { margin: 0 0 12px; font-size: 16px; color: #1e40af; }
.lipg-section .optional { font-weight: 400; font-size: 12px; color: #888; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.field-grid.indent { margin-top: 10px; }
.field-grid label { display: flex; flex-direction: column; font-size: 13px; color: #333; gap: 4px; }
.lipg-section > input, .field-grid input, .field-grid select {
    border: 1px solid #ccc; border-radius: 4px; padding: 8px 10px; font-size: 14px;
    font-family: inherit; width: 100%; box-sizing: border-box; background: #fff;
}
textarea { border: 1px solid #ccc; border-radius: 4px; padding: 8px 10px; font-size: 14px; font-family: inherit; width: 100%; box-sizing: border-box; }

.checkbox-row { display: flex; align-items: center; gap: 8px; font-size: 14px; margin: 10px 0; color: #333;}
.hidden-field { display: none; }

button { margin: 5px; padding: 10px 10px; }
.center { display: flex; flex-wrap: wrap; justify-content: center; align-items: stretch; gap: 10px; }
#lipgGenerate { background: #1e40af; color: #fff; border: none; border-radius: 4px; cursor: pointer; width: 220px; }
#lipgGenerate:hover { background: #4caf50; }

#lipgResults { display: flex; flex-direction: column; gap: 16px; margin-top: 10px; }

.lipg-card { border: 1px solid #ccc; border-radius: 6px; padding: 14px; background: #fafafa; }
.lipg-card-meta { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: #555; margin-bottom: 8px; }
.lipg-count { font-weight: 700; }
.lipg-count.lipg-ok { color: #2e7d32; }
.lipg-count.lipg-warn { color: #b07800; }
.lipg-count.lipg-over { color: #c0392b; }

.lipg-text {
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: inherit;
    font-size: 14px;
    line-height: 150%;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 12px;
    margin: 0 0 10px;
}

.btn-small { padding: 6px 14px; margin: 0; }
.lipg-copy { background: #1e40af; color: #fff; border: none; border-radius: 4px; cursor: pointer; }
.lipg-copy:hover { background: #4caf50; }

@media (max-width: 600px) {
    .field-grid { grid-template-columns: 1fr; }
    .lipg-card-meta { flex-direction: column; align-items: flex-start; gap: 4px; }
}
