/* =============================================
   Recovery Mode – Old-Money Library Aesthetic
   ============================================= */

:root {
    /* Color palette: aged library materials */
    --recovery-burgundy: #4a1e1e;
    --recovery-burgundy-light: #6b2d2d;
    --recovery-cream: #f4ede3;
    --recovery-cream-dark: #e8dfd1;
    --recovery-charcoal: #2a2520;
    --recovery-charcoal-soft: #3d3730;
    --recovery-brass: #b8935e;
    --recovery-brass-dark: #9a7849;
    --recovery-text: #2a2520;
    --recovery-text-soft: #5a534a;
    --recovery-border: #d4c4b0;
    
    /* Typography scale */
    --font-serif: 'Cormorant Garamond', 'Baskerville', Georgia, serif;
    --font-sans: 'Inter', -apple-system, sans-serif;
    
    /* Spacing & rhythm */
    --recovery-container: 1140px;
    --recovery-narrow: 720px;
    --recovery-section: 6rem;
}

/* Recovery mode body override */
body.recovery-mode {
    background: var(--recovery-cream);
    color: var(--recovery-text);
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.7;
}

/* =============================================
   Header in recovery mode
   ============================================= */
body.recovery-mode .nt-header {
    background: var(--recovery-burgundy);
    border-bottom: 1px solid var(--recovery-burgundy-light);
}

body.recovery-mode .nt-logo-text {
    color: var(--recovery-cream);
    font-family: var(--font-serif);
    font-weight: 700;
    letter-spacing: 0.02em;
}

body.recovery-mode .nt-nav-link {
    color: var(--recovery-cream);
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    font-weight: 500;
    letter-spacing: 0.01em;
}

body.recovery-mode .nt-nav-link:hover {
    color: var(--recovery-brass);
    background: rgba(255, 255, 255, 0.05);
}

body.recovery-mode .nt-logo-mark {
    color: var(--recovery-brass);
    border-color: rgba(184, 147, 94, 0.45);
    background: rgba(184, 147, 94, 0.07);
    box-shadow: none;
}

.recovery-header-link {
    display: inline-flex;
    align-items: center;
    min-height: 42px;
    padding: 0.65rem 1.15rem;
    border: 1px solid rgba(184, 147, 94, 0.7);
    color: var(--recovery-cream);
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.11em;
    text-transform: uppercase;
    text-decoration: none;
    transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.recovery-header-link:hover {
    color: var(--recovery-burgundy);
    background: var(--recovery-brass);
    transform: translateY(-1px);
}

/* =============================================
   Recovery Hero
   ============================================= */
.recovery-hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.recovery-page-hero {
    min-height: 45vh;
    background: linear-gradient(135deg, var(--recovery-burgundy) 0%, var(--recovery-charcoal) 100%);
}

.recovery-page-hero .recovery-section-overline {
    color: var(--recovery-brass);
}

.recovery-page-hero .recovery-hero-title {
    margin-bottom: 1rem;
}

.recovery-page-hero .recovery-hero-subtitle {
    margin-bottom: 0;
}

.recovery-narrow {
    max-width: var(--recovery-narrow);
    margin-inline: auto;
}

.recovery-narrow-spaced {
    margin-bottom: 4rem;
}

.recovery-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(31, 27, 23, 0.78) 0%,
        rgba(74, 30, 30, 0.72) 52%,
        rgba(31, 27, 23, 0.76) 100%
    );
    z-index: 1;
}

.recovery-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.015) 2px,
            rgba(0, 0, 0, 0.015) 4px
        );
    pointer-events: none;
    z-index: 2;
    opacity: 0.4;
}

.recovery-hero-inner {
    position: relative;
    z-index: 3;
    max-width: var(--recovery-narrow);
    padding: 3rem 1.25rem;
}

.recovery-hero-overline {
    display: inline-block;
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--recovery-brass);
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.recovery-hero-title {
    font-family: var(--font-serif);
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 700;
    line-height: 1.15;
    color: var(--recovery-cream);
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

.recovery-hero-subtitle {
    font-family: var(--font-sans);
    font-size: 1.125rem;
    font-weight: 300;
    line-height: 1.8;
    color: rgba(244, 237, 227, 0.88);
    margin-bottom: 2.5rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.4s forwards;
}

.recovery-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.6s forwards;
}

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

/* =============================================
   Recovery Buttons
   ============================================= */
.recovery-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--recovery-cream);
    background: var(--recovery-brass);
    border: 2px solid var(--recovery-brass);
    border-radius: 2px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.recovery-btn-primary:hover {
    background: var(--recovery-brass-dark);
    border-color: var(--recovery-brass-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(184, 147, 94, 0.3);
}

.recovery-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--recovery-cream);
    background: transparent;
    border: 2px solid rgba(244, 237, 227, 0.3);
    border-radius: 2px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.recovery-btn-secondary:hover {
    border-color: var(--recovery-cream);
    background: rgba(244, 237, 227, 0.08);
    transform: translateY(-2px);
}

/* =============================================
   Recovery Page Content
   ============================================= */
.recovery-page-content {
    background: var(--recovery-cream);
    padding: var(--recovery-section) 0;
}

.recovery-section {
    padding: 4rem 0;
}

.recovery-section-header {
    max-width: var(--recovery-narrow);
    margin: 0 auto 4rem;
    text-align: center;
}

.recovery-section-overline {
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--recovery-brass);
    margin-bottom: 1rem;
}

.recovery-section-title {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    line-height: 1.25;
    color: var(--recovery-charcoal);
    margin-bottom: 1rem;
}

.recovery-section-desc {
    font-family: var(--font-sans);
    font-size: 1.0625rem;
    font-weight: 300;
    line-height: 1.7;
    color: var(--recovery-text-soft);
}

/* =============================================
   Recovery Cards
   ============================================= */
.recovery-grid {
    display: grid;
    gap: 2rem;
    margin-bottom: 3rem;
}

.recovery-grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.recovery-card {
    background: #fff;
    border: 1px solid var(--recovery-border);
    padding: 2.5rem 2rem;
    position: relative;
    transition: all 0.4s ease;
}

.recovery-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 0;
    background: var(--recovery-brass);
    transition: height 0.4s ease;
}

.recovery-card:hover::before {
    height: 100%;
}

.recovery-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(42, 37, 32, 0.12);
    border-color: var(--recovery-brass);
}

.recovery-card-number {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--recovery-brass);
    line-height: 1;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.recovery-card h3 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--recovery-charcoal);
    margin-bottom: 0.75rem;
}

.recovery-card p {
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--recovery-text-soft);
    margin: 0;
}

/* =============================================
   Recovery Pillars (value props)
   ============================================= */
.recovery-pillars {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2.5rem;
    margin-bottom: 4rem;
}

.recovery-pillar {
    text-align: center;
    padding: 2rem 1.5rem;
}

.recovery-pillar-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--recovery-burgundy), var(--recovery-burgundy-light));
    border-radius: 50%;
    color: var(--recovery-cream);
}

.recovery-pillar h3 {
    font-family: var(--font-serif);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--recovery-charcoal);
    margin-bottom: 0.75rem;
}

.recovery-pillar p {
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--recovery-text-soft);
    margin: 0;
}

/* =============================================
   Recovery CTA Block
   ============================================= */
.recovery-cta {
    background: linear-gradient(135deg, var(--recovery-burgundy) 0%, var(--recovery-charcoal) 100%);
    border: 1px solid var(--recovery-burgundy-light);
    padding: 4rem 3rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.recovery-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        repeating-linear-gradient(
            45deg,
            transparent,
            transparent 10px,
            rgba(255, 255, 255, 0.01) 10px,
            rgba(255, 255, 255, 0.01) 20px
        );
    pointer-events: none;
}

.recovery-cta h2 {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    font-weight: 700;
    color: var(--recovery-cream);
    margin-bottom: 1rem;
}

.recovery-cta p {
    font-family: var(--font-sans);
    font-size: 1.0625rem;
    line-height: 1.7;
    color: rgba(244, 237, 227, 0.85);
    max-width: 600px;
    margin: 0 auto 2rem;
}

/* =============================================
   Team Constellation (About page)
   ============================================= */
.team-constellation {
    position: relative;
    padding: 4rem 0;
}

.team-members {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 3rem 2rem;
    opacity: 1;
    transition: opacity 0.4s ease;
}

.team-members.is-transitioning {
    opacity: 0;
}

.team-member {
    text-align: center;
    position: relative;
}

.team-member-portrait {
    width: 160px;
    height: 160px;
    margin: 0 auto 1.5rem;
    position: relative;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid var(--recovery-brass);
    box-shadow: 0 4px 16px rgba(42, 37, 32, 0.15);
    transition: all 0.4s ease;
}

.team-member:hover .team-member-portrait {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(184, 147, 94, 0.3);
}

.team-member-portrait img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(0.2) contrast(1.05);
}

.team-member-portrait-initials {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--recovery-burgundy), var(--recovery-burgundy-light));
    color: var(--recovery-cream);
    font-family: var(--font-serif);
    font-size: 2.5rem;
    font-weight: 700;
}

.team-member-name {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--recovery-charcoal);
    margin-bottom: 0.25rem;
}

.team-member-position {
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--recovery-brass);
    margin-bottom: 1rem;
}

.team-member-bio {
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--recovery-text-soft);
    max-width: 320px;
    margin: 0 auto;
}

/* Team pagination */
.team-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-top: 3rem;
    padding-top: 3rem;
    border-top: 1px solid var(--recovery-border);
}

.team-pagination-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--recovery-charcoal);
    background: transparent;
    border: 1px solid var(--recovery-border);
    border-radius: 2px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.team-pagination-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.team-pagination-btn:not(:disabled):hover {
    background: var(--recovery-brass);
    color: var(--recovery-cream);
    border-color: var(--recovery-brass);
}

.team-pagination-numbers {
    display: flex;
    gap: 0.5rem;
}

.team-pagination-number {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--recovery-charcoal);
    background: transparent;
    border: 1px solid var(--recovery-border);
    border-radius: 2px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.team-pagination-number:hover,
.team-pagination-number.is-active {
    background: var(--recovery-brass);
    color: var(--recovery-cream);
    border-color: var(--recovery-brass);
}

.team-member[hidden] {
    display: none !important;
}

.team-member.is-leaving {
    opacity: 0;
    transform: translateY(12px);
}

.team-pagination-number[aria-current="page"] {
    background: var(--recovery-brass);
    color: var(--recovery-cream);
    border-color: var(--recovery-brass);
}

.recovery-form-intro {
    margin-bottom: 2rem;
}

.recovery-contact-panel {
    margin-bottom: 3rem;
}

.recovery-contact-methods {
    display: grid;
    gap: 1.25rem;
}

.recovery-contact-method {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.recovery-contact-icon {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    display: grid;
    place-items: center;
    color: var(--recovery-brass);
    background: var(--recovery-cream);
    border: 1px solid var(--recovery-border);
    border-radius: 50%;
}

.recovery-contact-label {
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--recovery-brass);
    margin-bottom: 0.25rem;
}

.recovery-contact-value {
    color: var(--recovery-charcoal);
}

.recovery-form-notice {
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--recovery-border);
    background: rgba(184, 147, 94, 0.09);
    color: var(--recovery-charcoal);
}

.recovery-form-notice.is-error {
    border-color: var(--recovery-burgundy-light);
    background: rgba(107, 45, 45, 0.08);
}

/* =============================================
   Recovery Form
   ============================================= */
.recovery-form-group {
    margin-bottom: 1.5rem;
}

.recovery-form-label {
    display: block;
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--recovery-charcoal);
    margin-bottom: 0.5rem;
}

.recovery-form-input,
.recovery-form-textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    color: var(--recovery-text);
    background: #fff;
    border: 1px solid var(--recovery-border);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.recovery-form-input:focus,
.recovery-form-textarea:focus {
    outline: none;
    border-color: var(--recovery-brass);
    box-shadow: 0 0 0 3px rgba(184, 147, 94, 0.1);
}

.recovery-form-textarea {
    min-height: 140px;
    resize: vertical;
}

.recovery-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
}

/* =============================================
   Recovery Mission Statement
   ============================================= */
.recovery-mission {
    background: #fff;
    border: 1px solid var(--recovery-border);
    border-left: 4px solid var(--recovery-brass);
    padding: 3rem 2.5rem;
    margin-bottom: 4rem;
}

.recovery-mission h2 {
    font-family: var(--font-serif);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--recovery-charcoal);
    margin-bottom: 1.5rem;
}

.recovery-mission p {
    font-family: var(--font-sans);
    font-size: 1.0625rem;
    line-height: 1.8;
    color: var(--recovery-text-soft);
    margin-bottom: 1.25rem;
}

.recovery-mission p:last-child {
    margin-bottom: 0;
}

/* =============================================
   Footer in recovery mode
   ============================================= */
body.recovery-mode .nt-footer {
    background: var(--recovery-burgundy);
    color: var(--recovery-cream);
    border-top: 1px solid var(--recovery-burgundy-light);
}

body.recovery-mode .nt-footer h4 {
    color: var(--recovery-brass);
    font-family: var(--font-serif);
    font-weight: 700;
}

body.recovery-mode .nt-footer a {
    color: rgba(244, 237, 227, 0.8);
    transition: color 0.3s ease;
}

body.recovery-mode .nt-footer a:hover {
    color: var(--recovery-brass);
}

body.recovery-mode .nt-footer p {
    color: rgba(244, 237, 227, 0.7);
}

body.recovery-mode .nt-footer-contact div {
    color: rgba(244, 237, 227, 0.8);
}

body.recovery-mode .nt-footer-contact svg {
    color: var(--recovery-brass);
}

/* =============================================
   Responsive
   ============================================= */
@media (max-width: 768px) {
    .recovery-hero {
        min-height: 70vh;
    }
    
    .recovery-hero-title {
        font-size: 2rem;
    }
    
    .recovery-hero-subtitle {
        font-size: 1rem;
    }
    
    .recovery-section {
        padding: 3rem 0;
    }
    
    .recovery-grid-3 {
        grid-template-columns: 1fr;
    }
    
    .recovery-pillars {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .team-members {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    
    .recovery-cta {
        padding: 3rem 1.5rem;
    }
    
    .recovery-form-grid {
        grid-template-columns: 1fr;
    }

    .recovery-header-link {
        display: none;
    }
}

@media (min-width: 769px) {
    body.recovery-mode .nt-nav {
        display: block;
    }
    
    body.recovery-mode .nt-mobile-toggle {
        display: none;
    }
}

/* =============================================
   Client portal header actions (recovery)
   ============================================= */
.recovery-header-link-solid {
    background: var(--recovery-brass);
    border-color: var(--recovery-brass);
    color: var(--recovery-burgundy);
}

.recovery-header-link-solid:hover {
    background: var(--recovery-brass-dark);
    border-color: var(--recovery-brass-dark);
    color: var(--recovery-cream);
}

body.recovery-mode .nt-mobile-nav {
    background: var(--recovery-burgundy);
    border-top: 1px solid var(--recovery-burgundy-light);
}

body.recovery-mode .nt-mobile-auth {
    border-top-color: var(--recovery-burgundy-light) !important;
}

body.recovery-mode .nt-mobile-auth .nt-btn {
    border-radius: 0;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

body.recovery-mode .nt-mobile-auth .nt-btn-outline {
    background: transparent;
    border: 1px solid rgba(184, 147, 94, 0.7);
    color: var(--recovery-cream);
}

body.recovery-mode .nt-mobile-auth .nt-btn-outline:hover {
    background: rgba(244, 237, 227, 0.08);
    color: var(--recovery-cream);
}

body.recovery-mode .nt-mobile-auth .nt-btn-primary {
    background: var(--recovery-brass);
    border: 1px solid var(--recovery-brass);
    color: var(--recovery-burgundy);
}

body.recovery-mode .nt-mobile-auth .nt-btn-primary:hover {
    background: var(--recovery-brass-dark);
    color: var(--recovery-cream);
}
