/* P7 Checkup — Styles (P7 Corporate Design) */

:root {
    --p7-sage: #8B9680;
    --p7-sage-light: #a8b09e;
    --p7-sage-dark: #6b7560;
    --p7-apricot: #E8B298;
    --p7-creme: #FAFAF9;
    --p7-khaki: #43473C;
    --p7-khaki-light: #5a5e50;
    --p7-border: rgba(139, 150, 128, 0.2);
    --p7-card-bg: rgba(139, 150, 128, 0.06);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Overpass', sans-serif;
    background: var(--p7-creme);
    color: var(--p7-khaki);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* Layout */
.app-container {
    max-width: 560px;
    margin: 0 auto;
    padding: 20px 18px 40px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

@media (min-width: 768px) {
    .app-container {
        padding: 40px 20px 60px;
    }
}

/* Logo */
.p7-logo {
    font-family: 'Cormorant Garamond', serif;
    font-size: 13px;
    color: var(--p7-sage-dark);
    text-align: center;
    letter-spacing: 0.06em;
    font-weight: 500;
    margin-bottom: 20px;
}

/* Headings */
.p7-h1 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 22px;
    font-weight: 500;
    color: var(--p7-khaki);
    text-align: center;
    line-height: 1.3;
    margin: 0 0 8px;
}

@media (min-width: 768px) {
    .p7-h1 {
        font-size: 28px;
    }
}

/* Subtitle */
.p7-sub {
    font-size: 13px;
    color: var(--p7-sage-dark);
    text-align: center;
    margin: 0 0 20px;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .p7-sub {
        font-size: 14px;
        margin-bottom: 28px;
    }
}

/* Card */
.p7-card {
    background: var(--p7-card-bg);
    border: 1px solid var(--p7-border);
    border-radius: 12px;
    padding: 14px;
}

@media (min-width: 768px) {
    .p7-card {
        padding: 18px;
    }
}

/* Button */
.p7-btn {
    display: block;
    width: 100%;
    padding: 12px;
    border-radius: 10px;
    border: none;
    background: var(--p7-sage);
    color: white;
    font-family: 'Overpass', sans-serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-align: center;
    letter-spacing: 0.02em;
    transition: background 0.2s ease;
}

.p7-btn:hover {
    background: var(--p7-sage-dark);
}

.p7-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@media (min-width: 768px) {
    .p7-btn {
        padding: 14px;
        font-size: 15px;
    }
}

.p7-btn-outline {
    background: transparent;
    border: 1px solid var(--p7-sage);
    color: var(--p7-sage-dark);
}

.p7-btn-outline:hover {
    background: rgba(139, 150, 128, 0.08);
}

/* Features (Landing) */
.features {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 16px;
}

@media (min-width: 768px) {
    .features {
        gap: 24px;
        margin-bottom: 24px;
    }
}

.feature {
    text-align: center;
}

.feature-num {
    font-size: 20px;
    font-weight: 500;
    color: var(--p7-khaki);
    font-family: 'Cormorant Garamond', serif;
}

@media (min-width: 768px) {
    .feature-num {
        font-size: 22px;
    }
}

.feature-label {
    font-size: 11px;
    color: var(--p7-sage-dark);
    margin-top: 2px;
}

.trust {
    font-size: 11px;
    color: var(--p7-sage-dark);
    text-align: center;
    margin-top: 12px;
}

/* Progress Bar */
.progress-wrap {
    margin-bottom: 16px;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(139, 150, 128, 0.15);
    border-radius: 2px;
    margin-bottom: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 4px;
    border-radius: 2px;
    background: var(--p7-sage);
    transition: width 0.3s ease;
}

.progress-text {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--p7-sage-dark);
}

/* Question Header */
.q-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}

.q-badge {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(139, 150, 128, 0.12);
    border: 1px solid rgba(139, 150, 128, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 500;
    color: var(--p7-sage-dark);
    flex-shrink: 0;
}

.q-meta {
    font-size: 12px;
    color: var(--p7-sage-dark);
    line-height: 1.4;
}

.q-meta-small {
    font-size: 10px;
    color: var(--p7-sage);
}

.q-num {
    font-size: 12px;
    color: var(--p7-sage);
    margin-left: auto;
    white-space: nowrap;
}

/* Question Text */
.q-text {
    font-size: 14px;
    color: var(--p7-khaki);
    line-height: 1.5;
    margin-bottom: 20px;
    font-weight: 500;
}

@media (min-width: 768px) {
    .q-text {
        font-size: 16px;
    }
}

/* Scale Buttons */
.scale-row {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.scale-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex: 1;
    cursor: pointer;
}

.sc {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 500;
    border: 2px solid rgba(139, 150, 128, 0.25);
    color: var(--p7-sage-dark);
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

@media (min-width: 768px) {
    .sc {
        width: 44px;
        height: 44px;
        font-size: 14px;
    }
}

.sc:hover {
    border-color: var(--p7-sage);
    background: rgba(139, 150, 128, 0.08);
}

.sc.active {
    background: var(--p7-sage);
    border-color: var(--p7-sage);
    color: white;
}

.sc-label {
    font-size: 10px;
    color: var(--p7-sage-dark);
}

/* Button Row */
.btn-row {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.btn-row .p7-btn-outline {
    flex: 0 0 auto;
    width: auto;
    padding: 12px 14px;
    font-size: 13px;
}

@media (min-width: 768px) {
    .btn-row .p7-btn-outline {
        padding: 14px 20px;
    }
}

.btn-row .p7-btn:not(.p7-btn-outline) {
    flex: 1;
}

/* Completion Screen */
.check-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(139, 150, 128, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
}

/* Form Fields */
.input-label {
    font-size: 12px;
    color: var(--p7-sage-dark);
    margin-bottom: 6px;
    display: block;
}

.input-field {
    width: 100%;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid var(--p7-border);
    background: rgba(139, 150, 128, 0.04);
    font-family: 'Overpass', sans-serif;
    font-size: 14px;
    color: var(--p7-khaki);
    outline: none;
}

.input-field:focus {
    border-color: var(--p7-sage);
}

.input-field.error {
    border-color: #c0392b;
}

.field-error {
    font-size: 11px;
    color: #c0392b;
    margin-top: 4px;
}

/* Desktop: Form Grid */
.form-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

@media (min-width: 768px) {
    .form-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 14px;
    }
}

/* Thank You */
.thankyou-sub {
    font-size: 12px;
    color: var(--p7-sage-dark);
    text-align: center;
    line-height: 1.6;
    margin-top: 16px;
}

/* Screen visibility */
.screen {
    display: none;
}

.screen.active {
    display: block;
}

/* Fade animation */
.fade-in {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Loading spinner */
.spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    vertical-align: middle;
    margin-right: 6px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Start button centered */
.start-btn-wrap {
    max-width: 320px;
    margin: 0 auto;
}
