/* ============================================
   K. Alden Gray DDS PLLC — Custom Styles
   Clean minimalist · Teal + Slate Grey
   ============================================ */

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

:root {
    --teal-900: #0a3d3d;
    --teal-800: #0f4f4f;
    --teal-700: #136363;
    --teal-600: #1a7a7a;
    --teal-500: #219090;
    --teal-400: #3aadaa;
    --teal-300: #6bbfbf;
    --teal-100: #d4efef;
    --teal-50:  #eaf7f7;
    
    --slate-950: #0c1522;
    --slate-900: #111d2e;
    --slate-800: #1a2d42;
    --slate-700: #243b54;
    --slate-600: #334e68;
    --slate-500: #4a6b8a;
    --slate-400: #6b8fa8;
    --slate-300: #94b3c7;
    --slate-200: #bdd3e0;
    --slate-100: #dce9f0;
    --slate-50:  #f0f6f9;
    
    --white: #ffffff;
    --off-white: #f8fbfb;
    
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

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

body {
    font-family: var(--font-sans);
    font-weight: 300;
    color: var(--slate-800);
    background: var(--white);
    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: inherit;
    text-decoration: none;
}

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

/* --- Navigation --- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: background 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
    padding: 0;
}

.nav.scrolled {
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 1px 0 var(--slate-100);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.nav-logo {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
    z-index: 1001;
}

.nav-logo-text {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 400;
    color: var(--white);
    letter-spacing: 0.02em;
    transition: color 0.4s var(--ease-out);
}

.nav-logo-sub {
    font-family: var(--font-sans);
    font-size: 0.6rem;
    font-weight: 400;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--teal-300);
    transition: color 0.4s var(--ease-out);
}

.nav.scrolled .nav-logo-text {
    color: var(--slate-900);
}

.nav.scrolled .nav-logo-sub {
    color: var(--teal-600);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-link {
    font-size: 0.8rem;
    font-weight: 400;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.8);
    transition: color 0.3s var(--ease-out);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--teal-400);
    transition: width 0.3s var(--ease-out);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--white);
}

.nav.scrolled .nav-link {
    color: var(--slate-500);
}

.nav.scrolled .nav-link:hover {
    color: var(--slate-900);
}

.nav-link--cta {
    color: var(--teal-300) !important;
    border: 1px solid rgba(58, 173, 170, 0.4);
    padding: 8px 18px;
    border-radius: 100px;
    transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out) !important;
}

.nav-link--cta::after {
    display: none;
}

.nav-link--cta:hover {
    background: var(--teal-500);
    color: var(--white) !important;
}

.nav.scrolled .nav-link--cta {
    color: var(--teal-600) !important;
    border-color: var(--teal-300);
}

.nav.scrolled .nav-link--cta:hover {
    background: var(--teal-600);
    color: var(--white) !important;
    border-color: var(--teal-600);
}

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

.nav-toggle-line {
    width: 22px;
    height: 1.5px;
    background: var(--white);
    transition: transform 0.3s var(--ease-out), opacity 0.3s var(--ease-out);
}

.nav.scrolled .nav-toggle-line {
    background: var(--slate-800);
}

.nav-toggle.active .nav-toggle-line:nth-child(1) {
    transform: translateY(6.5px) rotate(45deg);
}

.nav-toggle.active .nav-toggle-line:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active .nav-toggle-line:nth-child(3) {
    transform: translateY(-6.5px) rotate(-45deg);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 999;
    background: var(--slate-950);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s var(--ease-out), visibility 0.4s var(--ease-out);
}

.mobile-menu.open {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 28px;
}

.mobile-menu-link {
    font-family: var(--font-serif);
    font-size: 2rem;
    font-weight: 300;
    color: var(--slate-200);
    transition: color 0.3s var(--ease-out);
}

.mobile-menu-link:hover {
    color: var(--teal-400);
}

.mobile-menu-link--cta {
    font-family: var(--font-sans);
    font-size: 0.85rem;
    font-weight: 400;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--teal-400);
    margin-top: 12px;
    border: 1px solid var(--teal-700);
    padding: 12px 28px;
    border-radius: 100px;
}

/* --- Hero --- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(10, 40, 45, 0.82) 0%,
        rgba(15, 55, 58, 0.72) 50%,
        rgba(20, 65, 70, 0.65) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 780px;
    padding: 120px 24px 80px;
    text-align: center;
}

.hero-greeting {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 300;
    font-style: italic;
    letter-spacing: 0.08em;
    color: var(--teal-300);
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s var(--ease-out) 0.3s forwards;
}

.hero-headline {
    font-family: var(--font-serif);
    font-size: clamp(2.2rem, 5vw, 3.6rem);
    font-weight: 300;
    line-height: 1.2;
    color: var(--white);
    margin-bottom: 24px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s var(--ease-out) 0.5s forwards;
}

.hero-sub {
    font-size: 1.05rem;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.7;
    margin-bottom: 40px;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s var(--ease-out) 0.7s forwards;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s var(--ease-out) 0.9s forwards;
}

.hero-contact-mini {
    margin-top: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 0.04em;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s var(--ease-out) 1.1s forwards;
}

.hero-contact-mini a {
    color: rgba(255, 255, 255, 0.65);
    transition: color 0.3s var(--ease-out);
}

.hero-contact-mini a:hover {
    color: var(--teal-300);
}

.hero-scroll {
    position: absolute;
    bottom: 36px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 0;
    animation: fadeIn 0.8s var(--ease-out) 1.5s forwards;
}

.hero-scroll span {
    font-size: 0.65rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.4);
}

.hero-scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, rgba(255,255,255,0.4), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 400;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border-radius: 100px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.3s var(--ease-out);
    white-space: nowrap;
}

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

.btn--primary:hover {
    background: var(--teal-700);
    border-color: var(--teal-700);
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(26, 122, 122, 0.3);
}

.btn--outline {
    background: transparent;
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.35);
}

.btn--outline:hover {
    border-color: var(--white);
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
}

.btn--full {
    width: 100%;
}

/* --- Section Divider --- */
.section-divider {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.divider-line {
    height: 1px;
    background: var(--slate-100);
}

/* --- Section Labels --- */
.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 64px;
}

.section-label {
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--teal-600);
    margin-bottom: 16px;
}

.section-title {
    font-family: var(--font-serif);
    font-size: clamp(1.8rem, 3.5vw, 2.6rem);
    font-weight: 300;
    line-height: 1.25;
    color: var(--slate-900);
    margin-bottom: 20px;
}

.section-sub {
    font-size: 1rem;
    font-weight: 300;
    color: var(--slate-500);
    line-height: 1.7;
}

/* --- Services --- */
.services {
    padding: 100px 0;
    background: var(--white);
}

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

.service-card {
    padding: 36px 28px;
    border: 1px solid var(--slate-100);
    border-radius: 12px;
    transition: border-color 0.3s var(--ease-out), transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}

.service-card:hover {
    border-color: var(--teal-200);
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(10, 61, 61, 0.08);
}

.service-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: var(--teal-50);
    color: var(--teal-600);
    margin-bottom: 20px;
    transition: background 0.3s var(--ease-out);
}

.service-card:hover .service-icon {
    background: var(--teal-100);
}

.service-icon svg {
    stroke: var(--teal-600);
}

.service-title {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--slate-900);
    margin-bottom: 10px;
}

.service-desc {
    font-size: 0.9rem;
    font-weight: 300;
    color: var(--slate-500);
    line-height: 1.7;
}

/* --- About --- */
.about {
    padding: 100px 0;
    background: var(--off-white);
}

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

.about-image {
    border-radius: 12px;
    overflow: hidden;
    aspect-ratio: 4/5;
}

.about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s var(--ease-out);
}

.about-image:hover img {
    transform: scale(1.02);
}

.about-content {
    padding: 16px 0;
}

.about-title {
    font-family: var(--font-serif);
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 300;
    line-height: 1.25;
    color: var(--slate-900);
    margin-bottom: 28px;
}

.about-text {
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--slate-600);
    line-height: 1.8;
    margin-bottom: 20px;
}

.about-values {
    margin-top: 36px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.about-value {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.9rem;
    font-weight: 300;
    color: var(--slate-700);
}

.about-value-line {
    flex-shrink: 0;
    width: 32px;
    height: 1px;
    background: var(--teal-400);
}

/* --- Contact --- */
.contact {
    padding: 100px 0;
    background: var(--white);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: start;
}

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

.contact-item {
    padding-bottom: 28px;
    border-bottom: 1px solid var(--slate-100);
}

.contact-item:last-of-type {
    border-bottom: none;
}

.contact-item-label {
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--teal-600);
    margin-bottom: 8px;
}

.contact-item-value {
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--slate-700);
    line-height: 1.7;
}

.contact-item-value a {
    color: var(--slate-700);
    transition: color 0.3s var(--ease-out);
    border-bottom: 1px solid transparent;
}

.contact-item-value a:hover {
    color: var(--teal-600);
    border-bottom-color: var(--teal-300);
}

.contact-map {
    border-radius: 12px;
    overflow: hidden;
    margin-top: 4px;
}

/* --- Contact Form --- */
.contact-form-wrapper {
    background: var(--slate-50);
    border-radius: 16px;
    padding: 40px;
    border: 1px solid var(--slate-100);
}

.form-title {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--slate-900);
    margin-bottom: 28px;
}

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

.form-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--slate-500);
    margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    font-family: var(--font-sans);
    font-size: 0.9rem;
    font-weight: 300;
    color: var(--slate-800);
    background: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: 8px;
    outline: none;
    transition: border-color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--slate-300);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--teal-400);
    box-shadow: 0 0 0 3px rgba(58, 173, 170, 0.1);
}

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

.form-success {
    display: none;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    padding: 14px 18px;
    background: var(--teal-50);
    border: 1px solid var(--teal-100);
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--teal-700);
}

.form-success.show {
    display: flex;
}

.form-success svg {
    flex-shrink: 0;
    color: var(--teal-500);
}

/* --- Footer --- */
.footer {
    background: var(--slate-950);
    padding: 64px 0 0;
}

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

.footer-logo {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--white);
}

.footer-logo-sub {
    font-size: 0.65rem;
    font-weight: 400;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--teal-400);
    margin-top: 2px;
}

.footer-tagline {
    font-size: 0.85rem;
    font-weight: 300;
    color: var(--slate-400);
    line-height: 1.7;
    margin-top: 16px;
    max-width: 280px;
}

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

.footer-links a {
    font-size: 0.85rem;
    font-weight: 300;
    color: var(--slate-400);
    transition: color 0.3s var(--ease-out);
}

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

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

.footer-contact p {
    font-size: 0.85rem;
    font-weight: 300;
    color: var(--slate-400);
    line-height: 1.6;
}

.footer-contact a {
    transition: color 0.3s var(--ease-out);
}

.footer-contact a:hover {
    color: var(--teal-400);
}

.footer-bottom {
    padding: 24px 0;
    text-align: center;
}

.footer-bottom p {
    font-size: 0.75rem;
    font-weight: 300;
    color: var(--slate-600);
}

/* --- Animations --- */
@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    to { opacity: 1; }
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.4; transform: scaleY(1); }
    50% { opacity: 1; transform: scaleY(1.2); }
}

/* Scroll reveal */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

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

/* --- Responsive --- */
@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about-grid {
        gap: 40px;
    }
    
    .contact-grid {
        gap: 48px;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }
    
    .nav-links {
        display: none;
    }
    
    .hero-content {
        padding: 100px 20px 80px;
    }
    
    .hero-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-actions .btn {
        width: 100%;
    }
    
    .hero-contact-mini {
        flex-direction: column;
        gap: 6px;
        font-size: 0.75rem;
    }
    
    .services {
        padding: 72px 0;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .service-card {
        padding: 28px 24px;
    }
    
    .about {
        padding: 72px 0;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .about-image {
        aspect-ratio: 16/10;
    }
    
    .contact {
        padding: 72px 0;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .contact-form-wrapper {
        padding: 28px;
    }
    
    .footer-top {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .section-header {
        margin-bottom: 48px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }
    
    .nav-container {
        padding: 0 16px;
    }
    
    .hero-content {
        padding: 90px 16px 70px;
    }
    
    .hero-headline {
        font-size: 1.9rem;
    }
    
    .contact-form-wrapper {
        padding: 20px;
    }
}
