/* 
  MEDEON - DESIGN SYSTEM (TALKSPACE-INSPIRED)
  Aesthetics: Warm, clinical-calm, trustworthy, and premium.
*/

:root {
    /* Color Palette */
    --white:         #FFFFFF;
    --off-white:     #F7F5F2; /* Talkspace signature background */
    --cream:         #EDE8E0; /* Section divider / card background */
    --dark:          #1A1A1A; /* Headings */
    --body:          #4A4A4A; /* Paragraph text */
    --muted:         #8A8A8A; /* Captions, labels */
    --teal:          #00857A; /* Primary CTA */
    --teal-light:    #E8F5F4; /* Background tints */
    --teal-hover:    #006B62; /* Hover state */
    --accent-warm:   #F4A261; /* Warm amber accent */
    --border:        #E0DBD4; /* Subtle borders */
    --red:           #E05252; /* Critical triage */
    --yellow:        #E8A838; /* Moderate triage */
    --green:         #2D9B6F; /* Stable triage */
    
    /* Typography */
    --font-display:  'Playfair Display', serif;
    --font-body:     'DM Sans', sans-serif;
    --font-mono:     'DM Mono', monospace;

    /* Spacing */
    --max-width:     1120px;
    --section-pad:   6rem;
    --section-pad-m: 4rem;
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.75;
    color: var(--body);
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    color: var(--dark);
    font-family: var(--font-display);
    font-weight: 700;
}

h1 { font-size: clamp(3rem, 6vw, 5rem); line-height: 1.1; }
h2 { font-size: clamp(2rem, 4vw, 3.2rem); line-height: 1.2; }
h3 { font-family: var(--font-body); font-size: 1.1rem; font-weight: 700; }

p { margin-bottom: 1.5rem; }

italic {
    font-style: italic;
}

.emphasis {
    font-family: var(--font-display);
    font-style: italic;
    color: var(--teal);
}

/* Layout Utilities */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

section {
    padding: var(--section-pad) 0;
}

@media (max-width: 768px) {
    section { padding: var(--section-pad-m) 0; }
}

.bg-off-white { background-color: var(--off-white); }
.bg-white     { background-color: var(--white); }
.bg-cream     { background-color: var(--cream); }

/* Components */

/* Navbar */
nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    z-index: 1000;
    transition: box-shadow 0.3s ease;
}

nav.scrolled {
    box-shadow: 0 2px 16px rgba(0,0,0,0.08);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    overflow: hidden;
    height: 40px; /* Constrain the container height */
}

.logo-img {
    height: 140px; /* Oversized to compensate for internal whitespace */
    width: auto;
    margin: -50px -25px; /* Offset to center the actual logo content */
    display: block;
}

.footer-logo .logo-img {
    filter: invert(1) brightness(2); /* Invert colors for the dark footer */
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: var(--body);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--teal);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-family: var(--font-body);
}

.btn-primary {
    background: var(--teal);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--teal-hover);
    transform: translateY(-1px);
}

.btn-ghost {
    background: transparent;
    border: 2px solid var(--teal);
    color: var(--teal);
}

.btn-ghost:hover {
    background: var(--teal-light);
    transform: translateY(-1px);
}

.btn-sm {
    padding: 0.5rem 1.25rem;
    font-size: 0.875rem;
}

.btn-full {
    width: 100%;
}

/* Hero */
.hero {
    padding-top: 10rem;
    padding-bottom: 6rem;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}

.hero-tag {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--teal);
    margin-bottom: 1rem;
    display: block;
}

.hero-subheading {
    font-size: 1.1rem;
    color: var(--body);
    margin-bottom: 2.5rem;
    max-width: 540px;
}

.hero-ctas {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.social-proof {
    font-size: 0.85rem;
    color: var(--muted);
}

.social-proof span {
    margin: 0 0.5rem;
}

/* Dashboard Animation */
.dashboard-card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    padding: 1.5rem;
    border: 1px solid var(--border);
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
}

.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #2D9B6F;
    border-radius: 50%;
    margin-right: 4px;
}

.triage-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--off-white);
    opacity: 0;
    transform: translateY(10px);
}

.triage-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
    color: white;
    text-transform: uppercase;
    min-width: 60px;
    text-align: center;
}

.badge-red { background: var(--red); }
.badge-yellow { background: var(--yellow); color: var(--dark); }
.badge-green { background: var(--green); }

.triage-info { flex: 1; }
.triage-id { font-weight: 600; font-size: 0.9rem; display: block; }
.triage-time { font-size: 0.75rem; color: var(--muted); }

/* Stats Strip */
.stats-strip {
    background: var(--white);
    padding: 3rem 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1px 1fr 1px 1fr;
    align-items: center;
    text-align: center;
}

.stats-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    align-items: center;
    text-align: center;
}

.stat-item h4 {
    font-size: 2.5rem;
    color: var(--teal);
    margin-bottom: 0.25rem;
}

.stat-item p {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 0;
}

.divider {
    background: var(--border);
    height: 60px;
}

/* Section Header */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.eyebrow {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--teal);
    margin-bottom: 1rem;
    display: block;
}

.section-header p {
    max-width: 600px;
    margin: 1rem auto 0;
}

/* Cards */
.card {
    background: var(--white);
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    box-shadow: 0 4px 24px rgba(0,0,0,0.07);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
}

/* Problem Section */
.problem-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

blockquote {
    border-left: 4px solid var(--teal);
    padding-left: 2rem;
    margin: 2rem 0;
}

blockquote p {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-style: italic;
    color: var(--dark);
    line-height: 1.4;
}

.problem-cards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.problem-card {
    background: var(--cream);
}

/* Solution Steps */
.solution-flow {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
    position: relative;
    margin-top: 4rem;
}

.step {
    text-align: center;
    position: relative;
    z-index: 1;
}

.step-number {
    width: 48px;
    height: 48px;
    background: var(--teal);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-weight: 700;
    font-size: 1.2rem;
}

.step h4 {
    font-family: var(--font-body);
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.step p {
    font-size: 0.85rem;
    color: var(--body);
}

.solution-line {
    position: absolute;
    top: 24px;
    left: 10%;
    right: 10%;
    height: 2px;
    background: repeating-linear-gradient(to right, var(--teal) 0, var(--teal) 5px, transparent 5px, transparent 10px);
    z-index: 0;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.tag-mono {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    background: var(--teal-light);
    color: var(--teal);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    display: inline-block;
    margin-top: 1rem;
}

/* Triage Detail Cards */
.triage-detail-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.triage-detail-card {
    border-left: 8px solid;
    padding: 2.5rem;
}

.triage-detail-card .badge {
    display: inline-block;
    padding: 0.3rem 1rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.progress-container {
    height: 6px;
    background: rgba(0,0,0,0.05);
    border-radius: 3px;
    margin-top: 2rem;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    width: 0;
    transition: width 1s cubic-bezier(0.65, 0, 0.35, 1);
}

/* Comparison Table */
.comparison-container {
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
}

.comparison-table th, .comparison-table td {
    padding: 1.5rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.comparison-table th {
    background: var(--white);
    font-family: var(--font-body);
    font-weight: 700;
}

.comparison-table tr:last-child td {
    border-bottom: none;
}

.highlight-col {
    background: var(--teal-light) !important;
}

.check { color: var(--teal); font-weight: bold; }
.cross { color: var(--red); }
.maybe { color: var(--yellow); }

/* Market Cards */
.market-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.market-card h3 {
    font-size: 3rem;
    color: var(--teal);
    margin-bottom: 1rem;
}

/* Pricing Grid */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    align-items: center;
}

.pricing-card.featured {
    border: 2px solid var(--teal);
    transform: scale(1.05);
    z-index: 2;
}

.popular-badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--teal);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
}

.price {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark);
    margin: 1.5rem 0;
}

.price span {
    font-size: 1rem;
    color: var(--muted);
    font-weight: 400;
}

.pricing-list {
    list-style: none;
    margin-bottom: 2rem;
}

.pricing-list li {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pricing-list li::before {
    content: "✓";
    color: var(--teal);
}

/* Roadmap */
.roadmap-container {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    padding-left: 3rem;
}

.roadmap-line {
    position: absolute;
    left: 7px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.roadmap-item {
    position: relative;
    margin-bottom: 4rem;
}

.roadmap-dot {
    position: absolute;
    left: -32px;
    top: 0;
    width: 16px;
    height: 16px;
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: 50%;
    z-index: 1;
}

.roadmap-item.active .roadmap-dot {
    background: var(--teal);
    border-color: var(--teal);
    box-shadow: 0 0 0 4px var(--teal-light);
}

.roadmap-item.active .roadmap-line {
    background: var(--teal);
}

.phase-tag {
    font-family: var(--font-mono);
    color: var(--teal);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    display: block;
}

/* Team */
.team-grid {
    display: flex;
    justify-content: center;
    gap: 4rem;
    max-width: 1000px;
    margin: 0 auto;
}

.team-card {
    flex: 1;
    text-align: center;
}

.team-photo-container {
    width: 160px;
    height: 160px;
    margin: 0 auto 2rem;
    position: relative;
}

.team-photo {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--teal-light);
    box-shadow: 0 4px 12px rgba(0, 133, 122, 0.15);
    transition: transform 0.3s ease;
}

.team-card:hover .team-photo {
    transform: scale(1.05);
    border-color: var(--teal);
}

.photo-placeholder {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    border: 2px dashed var(--teal);
    background: var(--teal-light);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    color: var(--teal);
    font-family: var(--font-mono);
    font-size: 0.7rem;
    line-height: 1.2;
    padding: 1rem;
}

.team-card h4 {
    margin-bottom: 0.25rem;
}

.role-title {
    font-family: var(--font-mono);
    color: var(--teal);
    font-size: 0.75rem;
    text-transform: uppercase;
    display: block;
    margin-bottom: 1.5rem;
}

.linkedin-btn {
    background: #0A66C2;
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 999px;
    text-decoration: none;
    font-size: 0.8rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.team-bio-list {
    list-style: none;
    text-align: left;
    font-size: 0.9rem;
}

.team-bio-list li {
    margin-bottom: 0.5rem;
    position: relative;
    padding-left: 1rem;
}

.team-bio-list li::before {
    content: "·";
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* Contact */
.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-top: 3rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: var(--body);
}

.contact-item .icon {
    font-size: 1.2rem;
}

.contact-form {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.05);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: var(--font-body);
    transition: border-color 0.2s ease;
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--teal);
}

.success-message {
    display: none;
    text-align: center;
    padding: 2rem;
}

.success-message .check-icon {
    width: 48px;
    height: 48px;
    background: var(--green);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.5rem;
}

/* Footer */
footer {
    background: var(--dark);
    color: var(--white);
    padding: 5rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1.5fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-logo {
    color: var(--white);
    margin-bottom: 1.5rem;
}

.footer-tagline {
    color: #A0A0A0;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.footer-subtext {
    color: #666;
    font-size: 0.85rem;
}

.footer-links h5, .footer-contact h5 {
    color: var(--white);
    font-family: var(--font-body);
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: #A0A0A0;
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--white);
}

.footer-contact a {
    display: block;
    color: #A0A0A0;
    text-decoration: none;
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.footer-social {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.footer-social a {
    color: #666;
    font-size: 0.85rem;
}

.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    color: #666;
    font-size: 0.85rem;
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Mobile Nav */
.mobile-nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--dark);
    margin: 5px 0;
    transition: 0.3s;
}

@media (max-width: 992px) {
    .nav-links, .nav-cta {
        display: none;
    }
    
    .mobile-nav-toggle {
        display: block;
    }
    
    .hero-grid, .problem-grid, .feature-grid, .triage-detail-grid, .market-grid, .pricing-grid, .contact-grid, .footer-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .solution-flow {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .solution-line {
        display: none;
    }
    
    .pricing-card.featured {
        transform: scale(1);
    }
    
    .team-grid {
        flex-direction: column;
    }
    
    .hero-grid { text-align: center; }
    .hero-subheading { margin: 0 auto 2.5rem; }
    .hero-ctas { justify-content: center; }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .divider { display: none; }
}

/* Hamburger Active State */
.nav-open .mobile-nav-toggle span:nth-child(1) { transform: rotate(-45deg) translate(-5px, 6px); }
.nav-open .mobile-nav-toggle span:nth-child(2) { opacity: 0; }
.nav-open .mobile-nav-toggle span:nth-child(3) { transform: rotate(45deg) translate(-5px, -6px); }

.mobile-menu {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    height: 0;
    background: var(--white);
    overflow: hidden;
    transition: height 0.3s ease;
    z-index: 999;
}

.nav-open .mobile-menu {
    height: calc(100vh - 80px);
}

.mobile-menu-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4rem 2rem;
    gap: 2rem;
    list-style: none;
}

.mobile-menu-links a {
    text-decoration: none;
    color: var(--dark);
    font-size: 1.5rem;
    font-weight: 700;
}
