/* ============================================
   DIVINE OX - THEORY OF CHANGE GENERATOR
   style.css
   ============================================ */

/* --- RESET & BASE --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Nunito', 'Aptos', Calibri, sans-serif;
    background-color: #F0FAFA;
    color: #1F2937;
    font-size: 15px;
    line-height: 1.6;
}

/* --- HEADER --- */
.site-header {
    background-color: #1E3A3A;
    padding: 18px 40px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 20px;
    max-width: 1100px;
    margin: 0 auto;
}

.header-logo {
    height: 52px;
    width: auto;
}

.header-text h1 {
    color: #FFFFFF;
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 0.3px;
}

.header-text p {
    color: #14A3A8;
    font-size: 13px;
    font-weight: 400;
    margin-top: 2px;
}

/* --- MAIN CONTAINER --- */
.main-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 30px 20px 60px;
}

/* --- INTRO CARD --- */
.intro-card {
    background: #1E3A3A;
    border-radius: 12px;
    padding: 28px 32px;
    margin-bottom: 24px;
    color: #FFFFFF;
}

.intro-card h2 {
    font-size: 20px;
    font-weight: 800;
    margin-bottom: 10px;
    color: #FFFFFF;
}

.intro-card p {
    font-size: 14px;
    color: #d1f0f0;
    line-height: 1.7;
    margin-bottom: 18px;
}

.intro-outputs {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.output-badge {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
}

.output-badge.word {
    background: #14A3A8;
    color: #FFFFFF;
}

.output-badge.pptx {
    background: #F59719;
    color: #FFFFFF;
}

.output-badge.excel {
    background: #3B55A2;
    color: #FFFFFF;
}

/* --- CARDS --- */
.card {
    background: #FFFFFF;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    display: flex;
    overflow: hidden;
}

.card-accent {
    width: 6px;
    background-color: #0D6B6E;
    flex-shrink: 0;
}

.card-body {
    padding: 24px 28px;
    flex: 1;
}

.card-body h3 {
    font-size: 17px;
    font-weight: 800;
    color: #1E3A3A;
    margin-bottom: 8px;
}

.section-hint {
    font-size: 13px;
    color: #6B7280;
    margin-bottom: 18px;
}

/* --- TAB NAVIGATION --- */
.tab-nav {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 10px 20px;
    border-radius: 8px;
    border: 2px solid #0D6B6E;
    background: #FFFFFF;
    color: #0D6B6E;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.tab-btn:hover {
    background: #F0FAFA;
}

.tab-btn.active {
    background: #0D6B6E;
    color: #FFFFFF;
}

/* --- TAB CONTENT --- */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* --- FORM ELEMENTS --- */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #1E3A3A;
    margin-bottom: 6px;
}

.required {
    color: #E62B24;
}

.text-input {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #D1D5DB;
    border-radius: 8px;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    color: #1F2937;
    background: #FAFAFA;
    transition: border-color 0.2s;
}

.text-input:focus {
    outline: none;
    border-color: #14A3A8;
    background: #FFFFFF;
}

.textarea-input {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #D1D5DB;
    border-radius: 8px;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    color: #1F2937;
    background: #FAFAFA;
    resize: vertical;
    transition: border-color 0.2s;
}

.textarea-input:focus {
    outline: none;
    border-color: #14A3A8;
    background: #FFFFFF;
}

.select-input {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #D1D5DB;
    border-radius: 8px;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    color: #1F2937;
    background: #FAFAFA;
    cursor: pointer;
}

.select-input:focus {
    outline: none;
    border-color: #14A3A8;
}

/* --- ACTIVITIES GRID --- */
.activities-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 20px;
}

/* --- METRIC ROWS --- */
.metric-row {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #F3F4F6;
}

.metric-row:last-child {
    border-bottom: none;
}

.flex-grow {
    flex: 1;
}

.freq-field {
    width: 130px;
    flex-shrink: 0;
}

.ind-field {
    width: 120px;
    flex-shrink: 0;
}

.priority-field {
    width: 120px;
    flex-shrink: 0;
}

/* Priority colour coding */
.priority-select option[value="P"] { color: #166534; }
.priority-select option[value="S"] { color: #92400E; }
.priority-select option[value="T"] { color: #6B7280; }

/* --- BUTTONS --- */
.btn-primary {
    padding: 10px 22px;
    background: #14A3A8;
    color: #FFFFFF;
    border: none;
    border-radius: 8px;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-primary:hover {
    background: #0D6B6E;
}

.btn-secondary {
    padding: 8px 18px;
    background: #FFFFFF;
    color: #0D6B6E;
    border: 2px solid #0D6B6E;
    border-radius: 8px;
    font-family: 'Nunito', sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 8px;
}

.btn-secondary:hover {
    background: #F0FAFA;
}

.btn-generate {
    width: 100%;
    padding: 16px;
    background: #1E3A3A;
    color: #FFFFFF;
    border: none;
    border-radius: 10px;
    font-family: 'Nunito', sans-serif;
    font-size: 17px;
    font-weight: 800;
    cursor: pointer;
    transition: background 0.2s;
    letter-spacing: 0.3px;
}

.btn-generate:hover {
    background: #0D6B6E;
}

/* --- PASSWORD SECTION --- */
.password-row {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-top: 14px;
}

.password-row .text-input {
    max-width: 300px;
}

.error-msg {
    color: #E62B24;
    font-size: 13px;
    margin-top: 8px;
    font-weight: 600;
}

/* --- SUBMIT SECTION --- */
.submit-section {
    margin-top: 10px;
}

.submit-hint {
    text-align: center;
    font-size: 12px;
    color: #9CA3AF;
    margin-top: 10px;
}

/* --- UPLOAD AREA --- */
.upload-area {
    border: 2px dashed #14A3A8;
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    background: #F0FAFA;
    margin-bottom: 16px;
}

.upload-icon {
    font-size: 40px;
    margin-bottom: 12px;
}

.upload-area p {
    color: #1E3A3A;
    font-weight: 600;
    margin-bottom: 6px;
}

.upload-hint {
    font-size: 12px;
    color: #9CA3AF !important;
    font-weight: 400 !important;
    margin-bottom: 16px !important;
}

.file-list {
    margin-top: 8px;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #F0FAFA;
    border-radius: 6px;
    margin-bottom: 6px;
    font-size: 13px;
    color: #1E3A3A;
    font-weight: 600;
}

/* --- FOOTER --- */
.site-footer {
    background: #1E3A3A;
    color: #9CA3AF;
    text-align: center;
    padding: 18px;
    font-size: 13px;
}

/* --- RESPONSIVE --- */
@media (max-width: 650px) {
    .activities-grid {
        grid-template-columns: 1fr;
    }

    .metric-row {
        flex-direction: column;
    }

    .freq-field,
    .ind-field,
    .priority-field {
        width: 100%;
    }

    .header-inner {
        gap: 12px;
    }

    .header-logo {
        height: 38px;
    }

    .header-text h1 {
        font-size: 16px;
    }

    .tab-btn {
        font-size: 12px;
        padding: 8px 14px;
    }
}

/* --- PROCESSING CARD --- */
.processing-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 48px 32px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.processing-card h2 {
    font-size: 22px;
    font-weight: 800;
    color: #1E3A3A;
    margin-bottom: 12px;
}

.processing-card p {
    color: #6B7280;
    margin-bottom: 6px;
}

.processing-hint {
    font-size: 13px;
    color: #9CA3AF !important;
}

.spinner {
    width: 52px;
    height: 52px;
    border: 5px solid #F0FAFA;
    border-top: 5px solid #14A3A8;
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
    margin: 0 auto 24px;
}

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

.processing-steps {
    margin-top: 28px;
    text-align: left;
    max-width: 340px;
    margin-left: auto;
    margin-right: auto;
}

.step {
    padding: 10px 16px;
    border-radius: 8px;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #9CA3AF;
    background: #F9FAFB;
    transition: all 0.4s;
}

.step.active {
    background: #F0FAFA;
    color: #0D6B6E;
    border-left: 4px solid #14A3A8;
}

.step.done {
    background: #F0FDF4;
    color: #166534;
    border-left: 4px solid #22C55E;
}

/* --- SUCCESS CARD --- */
.success-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 48px 32px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.success-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.success-card h2 {
    font-size: 22px;
    font-weight: 800;
    color: #1E3A3A;
    margin-bottom: 10px;
}

.success-card p {
    color: #6B7280;
    margin-bottom: 24px;
}

.download-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 380px;
    margin: 0 auto;
}

.download-btn {
    display: block;
    padding: 14px 20px;
    border-radius: 10px;
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: opacity 0.2s;
}

.download-btn:hover {
    opacity: 0.88;
}

.download-btn.word {
    background: #1E3A3A;
    color: #FFFFFF;
}

.download-btn.pptx {
    background: #F59719;
    color: #FFFFFF;
}

.download-btn.excel {
    background: #3B55A2;
    color: #FFFFFF;
}

/* --- ERROR CARD --- */
.error-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 48px 32px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.error-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.error-card h2 {
    font-size: 22px;
    font-weight: 800;
    color: #1E3A3A;
    margin-bottom: 10px;
}

.error-card p {
    color: #6B7280;
}
