/* ============================================
   DERMATOLOGY PARTNERS PLLC - Main Stylesheet
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
    --primary: #57504B;
    --primary-dark: #3A3632;
    --primary-light: #EDE8E2;
    --secondary: #B5A36A;
    --secondary-dark: #96875A;
    --secondary-light: #F0EAD8;
    --accent: #C9A96E;
    --text: #211D1A;
    --text-light: #57504B;
    --text-muted: #7A726B;
    --bg: #FDFCFA;
    --bg-alt: #E3DDD3;
    --bg-dark: #2A2521;
    --border: #D6CFC6;
    --shadow-sm: 0 1px 3px rgba(58,54,50,0.08);
    --shadow-md: 0 4px 12px rgba(58,54,50,0.1);
    --shadow-lg: 0 8px 30px rgba(58,54,50,0.12);
    --shadow-xl: 0 20px 60px rgba(58,54,50,0.18);
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 20px;
    --font-heading: 'Cormorant Garamond', Georgia, serif;
    --font-body: 'Jost', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    color: var(--text);
    background: var(--bg);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--secondary);
}

ul {
    list-style: none;
}

/* --- Container --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.header .container {
    max-width: 1340px;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--text);
    line-height: 1.25;
    font-weight: 500;
    letter-spacing: 0.01em;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-body);
    font-weight: 500;
    font-size: 0.88rem;
    padding: 12px 28px;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background: transparent;
    color: #fff;
    border-color: rgba(255,255,255,0.5);
}

.btn-outline:hover {
    background: rgba(255,255,255,0.1);
    border-color: #fff;
    color: #fff;
}

.btn-white {
    background: #fff;
    color: var(--primary);
    border-color: #fff;
}

.btn-white:hover {
    background: var(--primary-light);
    border-color: var(--primary-light);
    color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-outline-white {
    background: transparent;
    color: #fff;
    border-color: rgba(255,255,255,0.4);
}

.btn-outline-white:hover {
    background: rgba(255,255,255,0.1);
    border-color: #fff;
    color: #fff;
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1rem;
}

.btn-sm {
    padding: 8px 20px;
    font-size: 0.85rem;
}

.btn-full {
    width: 100%;
}

/* --- Top Bar --- */
.top-bar {
    background: var(--bg-dark);
    color: rgba(255,255,255,0.7);
    font-size: 0.82rem;
    padding: 8px 0;
    position: relative;
    z-index: 1001;
}

.top-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-left, .top-bar-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.top-bar-link {
    color: rgba(255,255,255,0.7);
    display: flex;
    align-items: center;
    gap: 6px;
    transition: color var(--transition);
}

.top-bar-link:hover {
    color: #fff;
}

.top-bar-divider {
    color: rgba(255,255,255,0.2);
}

.btn-portal {
    background: var(--secondary);
    color: #fff !important;
    padding: 4px 14px;
    border-radius: var(--radius-sm);
    font-weight: 600;
}

.btn-portal:hover {
    background: var(--secondary-dark);
    color: #fff;
}

/* --- Header --- */
.header {
    position: sticky;
    top: 0;
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid var(--border);
    transition: all var(--transition);
}

.header.scrolled {
    box-shadow: var(--shadow-md);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 120px;
    gap: 16px;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    flex-shrink: 0;
}

.logo-img {
    height: 100px;
    width: auto;
    display: block;
    object-fit: contain;
}

/* Footer logo variant */
.footer-logo {
    gap: 14px;
}

.footer-icon-img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    flex-shrink: 0;
    filter: brightness(0) invert(1);
    opacity: 0.9;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
    color: #fff;
    line-height: 1.2;
}

.logo-tagline {
    font-size: 0.72rem;
    color: rgba(255,255,255,0.5);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 400;
}

/* Navigation */
.nav-list {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text);
    border-radius: var(--radius-sm);
    transition: all var(--transition);
}

.nav-link:hover {
    color: var(--primary);
    background: var(--primary-light);
}

.nav-link svg {
    transition: transform var(--transition);
}

/* Dropdown */
.nav-dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    min-width: 220px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all var(--transition);
    z-index: 100;
}

.nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-dropdown:hover .nav-link svg {
    transform: rotate(180deg);
}

.dropdown-menu li a {
    display: block;
    padding: 10px 16px;
    font-size: 0.88rem;
    color: var(--text);
    border-radius: var(--radius-sm);
    transition: all var(--transition);
}

.dropdown-menu li a:hover {
    background: var(--primary-light);
    color: var(--primary);
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.mobile-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: all var(--transition);
}

.mobile-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Hero Section --- */
.hero {
    position: relative;
    background: linear-gradient(135deg, var(--primary) 0%, #47403B 45%, var(--bg-dark) 100%);
    color: #fff;
    overflow: hidden;
    min-height: 600px;
    display: flex;
    align-items: center;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 50%, rgba(201, 169, 110, 0.18) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(181, 163, 106, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 60% 80%, rgba(87, 80, 75, 0.2) 0%, transparent 50%);
}

.hero-inner {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 60px;
    align-items: center;
    padding: 100px 24px 120px;
}

.hero-label {
    display: inline-block;
    font-size: 0.82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--secondary);
    margin-bottom: 16px;
}

.hero-title {
    font-size: 3.6rem;
    font-weight: 400;
    line-height: 1.1;
    color: #fff;
    margin-bottom: 20px;
    letter-spacing: 0.01em;
}

.hero-title .highlight {
    color: var(--secondary);
    position: relative;
}

.hero-subtitle {
    font-size: 1.08rem;
    line-height: 1.7;
    color: rgba(255,255,255,0.8);
    margin-bottom: 32px;
    max-width: 560px;
}

.hero-cta {
    display: flex;
    gap: 16px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.hero-badges {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.badge {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.85);
}

.badge svg {
    color: var(--secondary);
    flex-shrink: 0;
}

/* Hero Card */
.hero-card {
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: var(--radius-lg);
    padding: 32px;
    color: #fff;
}

.hero-card-icon {
    margin-bottom: 16px;
    color: var(--secondary);
}

.hero-card h3 {
    font-size: 1.15rem;
    color: #fff;
    margin-bottom: 16px;
}

.hours-list {
    margin-bottom: 20px;
}

.hours-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 0.88rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.85);
}

.hours-list li:last-child {
    border-bottom: none;
}

.hours-list li span:first-child {
    font-weight: 500;
}

/* Hero Wave */
.hero-wave {
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    line-height: 0;
}

.hero-wave svg {
    width: 100%;
    height: 80px;
}

/* --- Section Styles --- */
.section {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-label {
    font-size: 0.82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--secondary);
    margin-bottom: 12px;
}

.section-title {
    font-size: 2.6rem;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 16px;
    letter-spacing: 0.01em;
}

.section-subtitle {
    font-size: 1.05rem;
    color: var(--text-light);
    max-width: 640px;
    margin: 0 auto;
    line-height: 1.7;
}

.section-divider {
    width: 48px;
    height: 1px;
    background: var(--secondary);
    margin: 20px auto 0;
    border-radius: 0;
}

/* --- About Section --- */
.about {
    background: var(--bg);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-lead {
    font-size: 1.15rem;
    color: var(--text);
    font-weight: 500;
    line-height: 1.8;
    margin-bottom: 16px;
}

.about-content p {
    color: var(--text-light);
    margin-bottom: 16px;
    line-height: 1.8;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 36px;
    padding-top: 36px;
    border-top: 1px solid var(--border);
}

.stat {
    text-align: center;
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
}

.stat-plus {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--secondary);
}

.stat-label {
    display: block;
    font-size: 0.82rem;
    color: var(--text-light);
    margin-top: 6px;
    line-height: 1.4;
}

.about-photo {
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
    object-position: center top;
    border-radius: var(--radius-lg);
    display: block;
}

/* --- Certification Marks --- */
.credentials-cert-row {
    display: flex;
    gap: 28px;
    align-items: stretch;
    margin-bottom: 16px;
}

.credentials-cert-left {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.credentials-cert-row .provider-credentials {
    margin-bottom: 0;
}

.cert-marks {
    display: flex;
    flex-direction: column;
    gap: 14px;
    align-items: center;
    flex-shrink: 0;
    padding-top: 4px;
}

.cert-mark-img {
    height: 120px;
    width: auto;
    object-fit: contain;
}

/* --- Practice Photo Slideshow --- */
.practice-slideshow {
    position: relative;
    width: 100%;
    aspect-ratio: 4/5;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.practice-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.practice-slide.active {
    opacity: 1;
    pointer-events: auto;
}

/* Override img-level aspect-ratio/radius since the container handles both */
.practice-slide .about-photo {
    width: 100%;
    height: 100%;
    aspect-ratio: unset;
    border-radius: 0;
}

/* Prev / Next arrows — visible on hover */
.practice-prev,
.practice-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(20, 16, 12, 0.45);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(255,255,255,0.22);
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 3;
    opacity: 0;
    transition: opacity var(--transition), background var(--transition);
}

.practice-prev { left: 12px; }
.practice-next { right: 12px; }

.practice-slideshow:hover .practice-prev,
.practice-slideshow:hover .practice-next { opacity: 1; }

.practice-prev:hover,
.practice-next:hover { background: rgba(20, 16, 12, 0.7); }

/* Dot indicators */
.practice-dots {
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 7px;
    z-index: 3;
}

.practice-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.7);
    background: transparent;
    cursor: pointer;
    padding: 0;
    transition: background var(--transition), transform var(--transition), border-color var(--transition);
}

.practice-dot.active {
    background: #fff;
    border-color: #fff;
    transform: scale(1.3);
}

/* --- Services Section --- */
.services {
    background: var(--bg-alt);
}

.services-categories {
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.service-category {
    background: var(--bg);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
}

.service-category-header {
    padding: 48px 48px 32px;
    text-align: center;
}

.service-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.service-icon.medical {
    background: var(--primary-light);
    color: var(--primary);
}

.service-icon.surgical {
    background: #fef3e2;
    color: #d4840a;
}

.service-icon.cosmetic {
    background: #f3e8f4;
    color: #8b5a9e;
}

.service-category-header h3 {
    font-size: 1.6rem;
    margin-bottom: 8px;
}

.service-category-header p {
    color: var(--text-light);
    max-width: 500px;
    margin: 0 auto;
}

.service-items {
    padding: 0 48px 48px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.service-item {
    display: flex;
    gap: 16px;
    padding: 20px;
    border-radius: var(--radius-md);
    background: var(--bg-alt);
    transition: all var(--transition);
}

.service-item:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.service-item-icon {
    flex-shrink: 0;
    color: var(--primary);
    margin-top: 2px;
}

.service-item h4 {
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.service-item p {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.6;
}

/* --- Providers Section --- */
.providers {
    background: var(--bg);
}

.provider-card {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 48px;
    align-items: start;
    margin-bottom: 60px;
    padding: 48px;
    background: var(--bg-alt);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
}

.provider-card.reversed {
    grid-template-columns: 1fr 350px;
}

.provider-card.reversed .provider-image {
    order: 2;
}

.provider-card.reversed .provider-info {
    order: 1;
}

.provider-card:last-child {
    margin-bottom: 0;
}

.provider-photo {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    object-position: center top;
    border-radius: var(--radius-md);
    display: block;
}

#laura-graner .provider-photo {
    object-position: center 35%;
}

.provider-info h3 {
    font-size: 1.8rem;
    margin-bottom: 4px;
}

.provider-title {
    font-size: 1rem;
    color: var(--secondary-dark);
    font-weight: 500;
    margin-bottom: 16px;
}

.provider-bio {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 24px;
}

.provider-credentials {
    margin-bottom: 28px;
}

.provider-credentials h4 {
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text);
    margin-bottom: 12px;
}

.provider-credentials ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.provider-credentials li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.92rem;
    color: var(--text-light);
}

.credential-icon {
    color: var(--primary);
    flex-shrink: 0;
}

/* --- Why Choose Us --- */
.why-us {
    background: var(--bg-alt);
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.why-card {
    background: var(--bg);
    border-radius: var(--radius-lg);
    padding: 36px;
    text-align: center;
    border: 1px solid var(--border);
    transition: all var(--transition);
}

.why-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.why-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.why-card h3 {
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.why-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.7;
}

/* --- Patient Information --- */
.patient-info {
    background: var(--bg);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.info-card {
    padding: 36px;
    background: var(--bg-alt);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: all var(--transition);
}

.info-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.info-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.info-card h3 {
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.info-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 16px;
}

.insurance-list {
    list-style: none;
    padding: 0;
    margin: 0 0 16px 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px 16px;
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.7;
}

.insurance-list li::before {
    content: "✓\00a0";
    color: var(--accent);
    font-weight: 600;
}

.info-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary);
    transition: all var(--transition);
}

.info-link:hover {
    gap: 10px;
    color: var(--secondary-dark);
}

/* --- Testimonials / Reviews Carousel --- */
.testimonials {
    background: var(--bg-alt);
    overflow: hidden;
    padding-bottom: 80px;
}

/* Rating summary row */
.reviews-rating-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    margin: 12px 0 4px;
    flex-wrap: wrap;
}

.reviews-overall {
    display: flex;
    align-items: center;
    gap: 10px;
}

.reviews-score {
    font-family: var(--font-heading);
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1;
}

.reviews-stars-large {
    display: flex;
    gap: 3px;
    color: #f5a623;
}

.reviews-stars-large svg {
    width: 22px;
    height: 22px;
}

.reviews-count {
    font-size: 0.88rem;
    color: var(--text-muted);
    font-weight: 500;
}

.reviews-google-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    border: 1px solid var(--border);
    padding: 7px 16px;
    border-radius: 20px;
    transition: all var(--transition);
    background: var(--bg);
}

.reviews-google-link:hover {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary-dark);
}

/* Carousel outer — full viewport width strip */
.carousel-outer {
    position: relative;
    width: 100%;
    overflow: hidden;
    margin-top: 40px;
    /* fade edges */
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

/* The scrolling track */
.carousel-track {
    display: flex;
    gap: 24px;
    width: max-content;
    animation: scroll-left 40s linear infinite;
    will-change: transform;
}

/* Pause on hover */
.carousel-outer:hover .carousel-track {
    animation-play-state: paused;
}

@keyframes scroll-left {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Individual review card */
.review-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    width: 360px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
    box-shadow: var(--shadow-sm);
    transition: box-shadow var(--transition), transform var(--transition);
    cursor: default;
}

.review-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

/* Card top row: avatar + name + Google G */
.review-card-top {
    display: flex;
    align-items: center;
    gap: 12px;
}

.reviewer-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    text-transform: uppercase;
}

.reviewer-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.reviewer-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reviewer-date {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* Google G icon top-right */
.google-g {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    margin-left: auto;
}

/* Star row */
.review-stars {
    display: flex;
    gap: 3px;
    color: #f5a623;
}

.review-stars svg {
    width: 16px;
    height: 16px;
}

/* Review body text */
.review-text {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.75;
    font-style: italic;
    flex: 1;
}

/* --- Contact Section --- */
.contact {
    background: var(--bg);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.contact-info-panel {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.contact-detail {
    display: flex;
    gap: 16px;
}

.contact-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.contact-detail h4 {
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.contact-detail p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.6;
}

.contact-detail a {
    color: var(--primary);
}

.contact-detail a:hover {
    color: var(--secondary-dark);
}

.contact-hours {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.contact-hours li {
    display: flex;
    align-items: baseline;
    gap: 12px;
    font-size: 0.88rem;
    color: var(--text-light);
    max-width: 280px;
}

.contact-hours li span:first-child {
    font-weight: 500;
    color: var(--text);
    min-width: 100px;
    flex-shrink: 0;
}

/* Contact Form */
.contact-form-panel {
    background: var(--bg-alt);
    border-radius: var(--radius-lg);
    padding: 40px;
    border: 1px solid var(--border);
}

.contact-form-panel h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
}

.contact-form-panel > p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 28px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-group {
    margin-bottom: 20px;
}

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

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text);
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    transition: all var(--transition);
    outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(87, 80, 75, 0.12);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-note {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 12px;
    text-align: center;
}

/* Map */
.map-container {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
}

/* --- CTA Banner --- */
.cta-banner {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    padding: 80px 0;
}

.cta-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.cta-content h2 {
    font-size: 2rem;
    color: #fff;
    margin-bottom: 8px;
}

.cta-content p {
    font-size: 1.05rem;
    color: rgba(255,255,255,0.8);
}

.cta-actions {
    display: flex;
    gap: 16px;
    flex-shrink: 0;
}

/* --- Footer --- */
.footer {
    background: var(--bg-dark);
    color: rgba(255,255,255,0.7);
    padding: 80px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 48px;
    padding-bottom: 48px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

/* Footer logo — brass tinted, no background */
.footer-logo-link {
    display: inline-block;
    text-decoration: none;
    margin-bottom: 4px;
    transition: opacity var(--transition);
}

.footer-logo-link:hover {
    opacity: 0.8;
}

.footer-logo-img {
    height: 44px;
    width: auto;
    display: block;
    object-fit: contain;
    /* invert(1): white bg → black, logo elements → light
       sepia + saturate + brightness: shift to brass ~#B5A36A
       mix-blend-mode: screen: black pixels (value 0) vanish into any bg,
       leaving only the brass logo symbol & wordmark visible */
    filter: invert(1) sepia(1) saturate(2) brightness(0.75);
    mix-blend-mode: screen;
}

.footer-desc {
    font-size: 0.88rem;
    line-height: 1.7;
    margin-top: 20px;
    color: rgba(255,255,255,0.6);
}

.footer-links h4 {
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 20px;
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links a {
    color: rgba(255,255,255,0.6);
    font-size: 0.88rem;
    transition: color var(--transition);
}

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

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    font-size: 0.82rem;
}

.footer-bottom p {
    color: rgba(255,255,255,0.4);
}

.footer-bottom-links {
    display: flex;
    gap: 24px;
}

.footer-bottom-links a {
    color: rgba(255,255,255,0.4);
    font-size: 0.82rem;
}

.footer-bottom-links a:hover {
    color: rgba(255,255,255,0.7);
}

/* --- Back to Top --- */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(16px);
    transition: all var(--transition);
    z-index: 99;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

/* --- Animations --- */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.fade-in-right {
    opacity: 0;
    transform: translateX(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 40px;
        padding: 80px 24px 100px;
    }

    .hero-visual {
        display: none;
    }

    .hero-title {
        font-size: 2.6rem;
    }

    .about-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .about-image {
        order: -1;
    }

    .about-image-placeholder {
        aspect-ratio: 16/9;
    }

    .provider-card,
    .provider-card.reversed {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .provider-card.reversed .provider-image {
        order: 0;
    }

    .provider-card.reversed .provider-info {
        order: 0;
    }

    .provider-image-placeholder {
        aspect-ratio: 16/9;
    }

    .why-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .review-card {
        width: 300px;
    }

    .cta-inner {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .logo-img {
        height: 64px;
    }

    .top-bar-left {
        display: none;
    }

    .top-bar-inner {
        justify-content: flex-end;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 300px;
        height: 100vh;
        background: #fff;
        box-shadow: var(--shadow-xl);
        padding: 80px 24px 24px;
        transition: right var(--transition);
        overflow-y: auto;
        z-index: 999;
    }

    .nav.open {
        right: 0;
    }

    .nav-list {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }

    .nav-link {
        padding: 14px 16px;
        font-size: 1rem;
        border-bottom: 1px solid var(--border);
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        padding: 0 0 0 16px;
        background: var(--bg-alt);
        border-radius: 0;
    }

    .mobile-toggle {
        display: flex;
    }

    .header-actions .btn {
        display: none;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 0.95rem;
    }

    .hero-cta {
        flex-direction: column;
    }

    .hero-cta .btn {
        width: 100%;
        text-align: center;
    }

    .hero-badges {
        flex-direction: column;
        gap: 12px;
    }

    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .about-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }

    .stat-number {
        font-size: 1.8rem;
    }

    .service-items {
        grid-template-columns: 1fr;
        padding: 0 24px 32px;
    }

    .service-category-header {
        padding: 32px 24px 24px;
    }

    .why-grid {
        grid-template-columns: 1fr;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }

    .review-card {
        width: 280px;
        padding: 22px 24px;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .cta-banner {
        padding: 50px 0;
    }

    .cta-content h2 {
        font-size: 1.5rem;
    }

    .cta-actions {
        flex-direction: column;
        width: 100%;
    }

    .cta-actions .btn {
        width: 100%;
        text-align: center;
    }

    .provider-card {
        padding: 24px;
    }

    .contact-form-panel {
        padding: 24px;
    }
}

@media (max-width: 480px) {
    .hero-inner {
        padding: 60px 16px 80px;
    }

    .hero-title {
        font-size: 1.7rem;
    }

    .about-stats {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .stat {
        display: flex;
        align-items: center;
        gap: 12px;
        text-align: left;
    }

    .stat-label {
        margin-top: 0;
    }
}

/* Mobile menu overlay */
.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
}

.nav-overlay.active {
    opacity: 1;
    visibility: visible;
}


/* ============================================================
   CV PAGE
   ============================================================ */

/* Contact / header block */
.cv-contact-block {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding: 28px 32px;
    background: var(--bg-alt);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--secondary);
    margin-bottom: 48px;
    flex-wrap: wrap;
}

.cv-contact-grid {
    display: flex;
    gap: 48px;
    flex-wrap: wrap;
}

.cv-contact-grid p {
    font-size: 0.9rem;
    color: var(--text);
    line-height: 1.7;
    margin: 0;
}

.cv-contact-grid a {
    color: var(--primary);
    text-decoration: none;
}

.cv-contact-grid a:hover {
    color: var(--secondary-dark);
    text-decoration: underline;
}

.cv-print-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-light);
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 8px 18px;
    cursor: pointer;
    white-space: nowrap;
    transition: all var(--transition);
    align-self: center;
}

.cv-print-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* CV entry rows */
.cv-entry {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.cv-entry:last-of-type {
    border-bottom: none;
}

.cv-entry-main {
    font-size: 0.95rem;
    color: var(--text);
    font-weight: 500;
    line-height: 1.6;
}

.cv-entry-detail {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-top: 3px;
}

/* Numbered publication / presentation lists */
.cv-pub-list {
    padding-left: 20px;
    margin: 0 0 8px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cv-pub-list li {
    font-size: 0.92rem;
    color: var(--text);
    line-height: 1.75;
}

.cv-pub-list li em {
    font-style: italic;
    color: var(--text-light);
}

/* Print styles */
@media print {
    .top-bar, .header, .footer, .back-to-top, .cv-print-btn {
        display: none !important;
    }
    .legal-hero {
        background: none !important;
        color: var(--text) !important;
        padding: 20px 0 12px;
    }
    .legal-hero h1, .legal-hero p {
        color: var(--text) !important;
    }
    .legal-content {
        padding: 0;
    }
    .cv-contact-block {
        border: 1px solid var(--border);
        page-break-inside: avoid;
    }
    .legal-section {
        page-break-inside: avoid;
    }
    .cv-pub-list li {
        page-break-inside: avoid;
    }
}

@media (max-width: 600px) {
    .cv-contact-block {
        flex-direction: column;
        padding: 20px;
    }
    .cv-contact-grid {
        flex-direction: column;
        gap: 16px;
    }
}

/* ============================================================
   LEGAL PAGES (Privacy Policy, Terms of Use, Accessibility)
   ============================================================ */

.legal-hero {
    background: linear-gradient(135deg, var(--primary) 0%, #47403B 60%, var(--bg-dark) 100%);
    color: #fff;
    padding: 100px 0 64px;
    text-align: center;
}

.legal-hero-label {
    font-size: 0.75rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--secondary-light);
    margin-bottom: 14px;
    font-family: var(--font-body);
}

.legal-hero h1 {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 500;
    color: #fff;
    margin-bottom: 12px;
    letter-spacing: 0.01em;
}

.legal-hero-meta {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.65);
    font-family: var(--font-body);
}

.legal-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 64px 24px 96px;
}

.legal-toc {
    background: var(--bg-alt);
    border-radius: var(--radius-md);
    padding: 28px 32px;
    margin-bottom: 52px;
    border-left: 3px solid var(--secondary);
}

.legal-toc h3 {
    font-family: var(--font-heading);
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--primary-dark);
    margin-bottom: 14px;
}

.legal-toc ol {
    margin: 0;
    padding-left: 20px;
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.legal-toc a {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color var(--transition);
}

.legal-toc a:hover {
    color: var(--secondary-dark);
    text-decoration: underline;
}

.legal-section {
    margin-bottom: 52px;
    scroll-margin-top: 150px;
}

.legal-section h2 {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    font-weight: 500;
    color: var(--primary-dark);
    margin-bottom: 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
    letter-spacing: 0.01em;
}

.legal-section h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 500;
    color: var(--primary);
    margin: 24px 0 10px;
}

.legal-section p {
    color: var(--text);
    line-height: 1.85;
    margin-bottom: 14px;
    font-size: 0.95rem;
}

.legal-section ul,
.legal-section ol {
    color: var(--text);
    line-height: 1.85;
    padding-left: 24px;
    margin-bottom: 14px;
    font-size: 0.95rem;
}

.legal-section li {
    margin-bottom: 7px;
}

.legal-section a {
    color: var(--primary);
    text-decoration: underline;
}

.legal-section a:hover {
    color: var(--secondary-dark);
}

.legal-contact-box {
    background: var(--bg-alt);
    border-radius: var(--radius-md);
    padding: 28px 32px;
    margin-top: 32px;
    border-left: 3px solid var(--accent);
}

.legal-contact-box h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 500;
    color: var(--primary-dark);
    margin-bottom: 12px;
}

.legal-contact-box p {
    margin-bottom: 7px;
    font-size: 0.9rem;
    color: var(--text);
    line-height: 1.7;
}

.legal-contact-box a {
    color: var(--primary);
    text-decoration: underline;
}

@media (max-width: 768px) {
    .legal-hero {
        padding: 80px 0 48px;
    }
    .legal-toc {
        padding: 20px 20px;
    }
    .legal-contact-box {
        padding: 20px 20px;
    }
}


/* ============================================================
   EASTER EGG
   ============================================================ */

.easter-egg-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(10, 8, 6, 0.92);
    z-index: 99999;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.easter-egg-overlay.active {
    display: flex;
    animation: eggFadeIn 0.3s ease;
}

@keyframes eggFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.easter-egg-card {
    text-align: center;
    position: relative;
    padding: 48px 56px;
    pointer-events: none;
    overflow: visible;
}

.easter-egg-logo {
    margin-bottom: 28px;
}

.claude-star {
    width: 120px;
    height: 120px;
    display: block;
    margin: 0 auto;
    border-radius: 26px;
    animation: sway 2s ease-in-out infinite;
    filter: drop-shadow(0 0 22px rgba(215, 118, 85, 0.65)) drop-shadow(0 4px 12px rgba(0,0,0,0.4));
}

@keyframes sway {
    0%   { transform: rotate(-18deg); }
    50%  { transform: rotate(18deg);  }
    100% { transform: rotate(-18deg); }
}

.easter-egg-msg {
    color: rgba(255, 255, 255, 0.82);
    font-family: var(--font-body);
    font-size: 1.1rem;
    font-weight: 300;
    letter-spacing: 0.04em;
    margin: 0 0 8px;
}

.easter-egg-brand {
    font-family: 'Courier New', 'Lucida Console', 'Courier', monospace;
    color: #DA7756;
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    margin: 0 0 24px;
    text-shadow:
        0 0 8px rgba(218, 119, 86, 0.9),
        0 0 20px rgba(218, 119, 86, 0.5),
        0 0 40px rgba(218, 119, 86, 0.25),
        2px 2px 0px rgba(0,0,0,0.4);
}

.easter-egg-dismiss {
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.28);
    margin: 0;
}

/* Sparkle particles */
.easter-egg-particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: visible;
}

.sparkle {
    position: absolute;
    border-radius: 50%;
    opacity: 0;
    animation: floatUp var(--dur) ease-out var(--delay) infinite;
}

@keyframes floatUp {
    0%   { transform: translateY(0)    scale(1);   opacity: 0.9; }
    80%  { opacity: 0.4; }
    100% { transform: translateY(-180px) scale(0); opacity: 0;   }
}

/* ============================================
   CHAT WIDGET
   ============================================ */

/* --- Floating Action Button --- */
.chat-fab {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--secondary);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(181, 163, 106, 0.4);
    z-index: 9998;
    transition: background 0.3s, transform 0.3s, box-shadow 0.3s;
}

.chat-fab:hover {
    background: var(--secondary-dark);
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(181, 163, 106, 0.5);
}

.chat-fab-icon {
    transition: opacity 0.25s, transform 0.25s;
    position: absolute;
}

.chat-fab-close {
    opacity: 0;
    transform: rotate(-90deg);
}

.chat-widget.open .chat-fab-open {
    opacity: 0;
    transform: rotate(90deg);
}

.chat-widget.open .chat-fab-close {
    opacity: 1;
    transform: rotate(0deg);
}

/* Pulse animation on load */
@keyframes chatPulse {
    0%, 100% { box-shadow: 0 4px 16px rgba(181, 163, 106, 0.4); }
    50% { box-shadow: 0 4px 24px rgba(181, 163, 106, 0.7), 0 0 0 8px rgba(181, 163, 106, 0.15); }
}

.chat-fab.pulse {
    animation: chatPulse 2s ease-in-out 3;
}

/* --- Chat Panel --- */
.chat-panel {
    position: fixed;
    bottom: 100px;
    right: 24px;
    width: 380px;
    max-height: 560px;
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    display: flex;
    flex-direction: column;
    z-index: 9999;
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    overflow: hidden;
    border: 1px solid var(--border);
}

.chat-widget.open .chat-panel {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

/* --- Chat Header --- */
.chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: var(--primary);
    color: #fff;
    flex-shrink: 0;
}

.chat-header-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.chat-header-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-header-avatar svg {
    color: #fff;
}

.chat-header-title {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    display: block;
    line-height: 1.2;
}

.chat-header-status {
    font-size: 0.75rem;
    opacity: 0.8;
    display: block;
}

.chat-close {
    background: rgba(255,255,255,0.1);
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.chat-close:hover {
    background: rgba(255,255,255,0.25);
}

/* --- Chat Messages --- */
.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: 280px;
    max-height: 360px;
    scroll-behavior: smooth;
}

.chat-msg {
    display: flex;
    gap: 8px;
    max-width: 88%;
    animation: chatMsgIn 0.3s ease;
}

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

.chat-msg-bot {
    align-self: flex-start;
}

.chat-msg-user {
    align-self: flex-end;
}

.chat-msg-bubble {
    padding: 10px 14px;
    border-radius: 16px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    line-height: 1.5;
    word-wrap: break-word;
}

.chat-msg-bot .chat-msg-bubble {
    background: var(--primary-light);
    color: var(--text);
    border-bottom-left-radius: 4px;
}

.chat-msg-user .chat-msg-bubble {
    background: var(--secondary);
    color: #fff;
    border-bottom-right-radius: 4px;
}

/* Links inside bot messages */
.chat-msg-bot .chat-msg-bubble a {
    color: var(--secondary-dark);
    text-decoration: underline;
    word-break: break-all;
}

.chat-msg-bot .chat-msg-bubble a:hover {
    color: var(--primary);
}

/* --- Typing Indicator --- */
.chat-typing {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 12px 16px;
    align-self: flex-start;
}

.chat-typing-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--text-muted);
    animation: typingBounce 1.4s ease-in-out infinite;
}

.chat-typing-dot:nth-child(2) { animation-delay: 0.2s; }
.chat-typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
    30% { transform: translateY(-6px); opacity: 1; }
}

/* --- Quick Action Buttons --- */
.chat-quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 0 4px;
}

.chat-quick-btn {
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text);
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
    white-space: nowrap;
}

.chat-quick-btn:hover {
    background: var(--secondary-light);
    border-color: var(--secondary);
    color: var(--secondary-dark);
}

/* --- Disclaimer --- */
.chat-disclaimer {
    padding: 6px 16px;
    font-family: var(--font-body);
    font-size: 0.7rem;
    color: var(--text-muted);
    text-align: center;
    border-top: 1px solid var(--border);
    flex-shrink: 0;
}

/* --- Chat Input Area --- */
.chat-input-area {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    padding: 10px 12px 14px;
    border-top: 1px solid var(--border);
    background: #fff;
    flex-shrink: 0;
}

.chat-input {
    flex: 1;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 10px 16px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    resize: none;
    outline: none;
    max-height: 100px;
    line-height: 1.4;
    transition: border-color 0.2s;
    background: var(--bg);
}

.chat-input:focus {
    border-color: var(--secondary);
}

.chat-input::placeholder {
    color: var(--text-muted);
}

.chat-send {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: var(--secondary);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s, opacity 0.2s;
}

.chat-send:hover:not(:disabled) {
    background: var(--secondary-dark);
}

.chat-send:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* --- Chat Error Message --- */
.chat-msg-error .chat-msg-bubble {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* --- Mobile Responsive --- */
@media (max-width: 480px) {
    .chat-panel {
        top: 0;
        bottom: 0;
        right: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        height: 100dvh;
        max-height: none;
        border-radius: 0;
        border: none;
    }

    .chat-messages {
        flex: 1;
        max-height: none;
        min-height: 0;
    }

    .chat-fab {
        bottom: 16px;
        right: 16px;
    }

    .chat-widget.open .chat-fab {
        display: none;
    }
}
