/* ==========================================================================
   HNO König Borken – Stylesheet
   Handgeschrieben, kein Build-Schritt. Farben und Abstände entsprechen dem
   früheren Tailwind-Design (brand = Marineblau, Akzent = Smaragdgrün).
   ========================================================================== */

/* --- Schriften (lokal, keine externen Anfragen) -------------------------- */

@font-face {
    font-family: 'Open Sans';
    src: url('font-open-sans/OpenSans-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Open Sans';
    src: url('font-open-sans/OpenSans-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Open Sans';
    src: url('font-open-sans/OpenSans-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Nunito';
    src: url('font-nunito/Nunito-ExtraBold.ttf') format('truetype');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

/* --- Design-Tokens ------------------------------------------------------- */

:root {
    --brand-50:  #eef3f9;
    --brand-100: #d3e0ef;
    --brand-700: #234c75;
    --brand-800: #1b3a5f;
    --brand-900: #152944;
    --brand-950: #0d1f35;

    --accent:      #059669;
    --accent-dot:  #10b981;

    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-500: #64748b;
    --slate-600: #475569;

    --white: #ffffff;

    --font-sans: 'Open Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --font-display: 'Nunito', 'Arial Black', sans-serif;

    --header-height: 4rem;
    --radius: 1rem;
    --radius-lg: 1.5rem;
}

/* --- Grundlagen ---------------------------------------------------------- */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-height) + 1rem);
    -webkit-text-size-adjust: 100%;
}

body {
    /* Flex-Spalte, damit der Fußbereich auch auf kurzen Seiten unten sitzt. */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
    background-color: var(--white);
    color: var(--brand-950);
    font-family: var(--font-sans);
    font-size: 1rem;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

main {
    flex: 1 0 auto;
}

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

a {
    color: inherit;
}

h1, h2, h3 {
    margin: 0;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

p {
    margin: 0;
}

ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

hr {
    border: 0;
    border-top: 1px solid var(--slate-200);
    margin: 2rem 0;
}

.icon {
    width: 1.25rem;
    height: 1.25rem;
    flex: none;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 100;
    padding: 0.75rem 1.25rem;
    background: var(--white);
    color: var(--brand-950);
    font-weight: 600;
}

.skip-link:focus {
    left: 0;
}

:focus-visible {
    outline: 2px solid var(--accent-dot);
    outline-offset: 2px;
}

/* --- Layout-Container ---------------------------------------------------- */

.wrap {
    width: 100%;
    max-width: 72rem;
    margin: 0 auto;
    padding: 0 1rem;
}

.wrap--medium { max-width: 64rem; }
.wrap--narrow { max-width: 48rem; }

.section {
    padding: 4rem 0;
}

.section--tint {
    background-color: var(--brand-50);
    border-block: 1px solid var(--slate-200);
}

.section__title {
    margin-top: 0.5rem;
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--brand-950);
}

.section__title--spaced {
    margin-top: 3rem;
}

.section__lead {
    margin-top: 0.75rem;
    color: var(--slate-600);
}

.section__note {
    display: flex;
    gap: 0.625rem;
    align-items: flex-start;
    margin-top: 1.5rem;
    font-size: 0.9375rem;
    color: var(--slate-600);
}

.section__note .icon {
    margin-top: 0.2rem;
    color: var(--accent);
}

.section__note a {
    color: var(--brand-700);
    font-weight: 600;
    text-underline-offset: 2px;
}

.eyebrow {
    margin: 0;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--accent);
}

.eyebrow--small {
    font-size: 0.625rem;
}

/* --- Kopfbereich --------------------------------------------------------- */

.site-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 50;
    background-color: var(--brand-950);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.site-header__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    height: var(--header-height);
    max-width: 72rem;
    margin: 0 auto;
    padding: 0 1rem;
}

.site-header__right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.wordmark {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.wordmark__logo {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.5rem;
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--white);
}

.wordmark__claim {
    display: none;
    max-width: 15rem;
    font-size: 0.625rem;
    font-weight: 600;
    line-height: 1.3;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: rgba(255, 255, 255, 0.55);
}

.nav {
    display: flex;
    gap: 0.25rem;
}

.nav--desktop {
    display: none;
}

.nav__link {
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.65);
    transition: background-color 0.2s, color 0.2s;
}

.nav__link:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--white);
}

.nav__link.is-active {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--white);
}

.nav-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 0.5rem;
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--white);
    cursor: pointer;
}

.nav-toggle__close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__close { display: block; }

.nav-mobile {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background-color: var(--brand-950);
}

.nav--mobile {
    flex-direction: column;
    max-width: 72rem;
    margin: 0 auto;
    padding: 0.75rem 1rem;
}

.nav--mobile .nav__link {
    padding: 0.625rem 0.75rem;
}

/* --- Startseite: Hero ---------------------------------------------------- */

.hero {
    position: relative;
    isolation: isolate;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100vh;
    overflow: hidden;
    padding: calc(var(--header-height) + 3rem) 1rem 3rem;
}

.hero__bg,
.hero__overlay {
    position: absolute;
    inset: 0;
}

.hero__bg {
    z-index: -2;
    background: url('../images/praxis_1.jpg') center / cover no-repeat;
}

.hero__overlay {
    z-index: -1;
    background-color: rgba(13, 31, 53, 0.8);
}

.hero__inner {
    width: 100%;
    max-width: 72rem;
    margin: 0 auto;
}

.hero__intro {
    max-width: 42rem;
}

.hero__title {
    margin-top: 1rem;
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1.1;
    color: var(--white);
}

.hero__lead {
    max-width: 36rem;
    margin-top: 1rem;
    color: rgba(255, 255, 255, 0.75);
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    background-color: rgba(255, 255, 255, 0.05);
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
}

.badge .icon {
    width: 0.875rem;
    height: 0.875rem;
}

/* --- Schaltflächen ------------------------------------------------------- */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 0.75rem;
    font-size: 0.875rem;
    font-weight: 700;
    text-decoration: none;
    transition: background-color 0.2s, border-color 0.2s;
}

.btn .icon {
    width: 1rem;
    height: 1rem;
}

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

.btn--primary:hover {
    background-color: var(--brand-50);
}

.btn--ghost {
    border: 1px solid rgba(255, 255, 255, 0.3);
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--white);
}

.btn--ghost:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.btn--dark {
    background-color: var(--brand-800);
    color: var(--white);
}

.btn--dark:hover {
    background-color: var(--brand-950);
}

/* --- Ärztekarten --------------------------------------------------------- */

.doctors {
    display: grid;
    gap: 1rem;
    margin-top: 2.5rem;
}

.doctor {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.7);
    border-radius: var(--radius-lg);
    background-color: rgba(255, 255, 255, 0.92);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(12px);
    transition: background-color 0.3s;
}

.doctor:hover {
    background-color: var(--white);
}

.doctor__img {
    width: 6rem;
    height: 7rem;
    flex: none;
    object-fit: cover;
    border: 1px solid var(--brand-100);
    border-radius: var(--radius);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.doctor__body {
    min-width: 0;
}

.doctor__name {
    margin-top: 0.25rem;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--brand-950);
}

.doctor__list {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(21, 41, 68, 0.15);
    display: grid;
    gap: 0.375rem;
}

.doctor__list li {
    position: relative;
    padding-left: 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: rgba(13, 31, 53, 0.8);
}

.doctor__list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 999px;
    background-color: var(--accent-dot);
}

/* --- Karten / Boxen ------------------------------------------------------ */

.card {
    padding: 1.5rem;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
    background-color: var(--white);
}

.card--accent {
    border-left: 4px solid var(--accent);
}

.card--spaced {
    margin-top: 1.5rem;
}

.card__label {
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--slate-500);
}

.card__title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--brand-950);
}

.card + .prose,
.card__title + .prose {
    margin-top: 0.75rem;
}

/* --- Geänderte Öffnungszeiten -------------------------------------------- */

.changes {
    display: grid;
    gap: 0.75rem;
}

.changes__item {
    display: grid;
    gap: 0.125rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--slate-100);
}

.changes__item:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.changes__date {
    font-weight: 700;
    color: var(--brand-950);
    font-variant-numeric: tabular-nums;
}

.changes__text {
    color: var(--slate-600);
}

.changes__empty {
    color: var(--slate-600);
}

/* --- Sprechzeitentabelle ------------------------------------------------- */

.table-scroll {
    overflow-x: auto;
}

.schedule {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    text-align: left;
}

.schedule th,
.schedule td {
    padding: 0.5rem 0.75rem 0.5rem 0;
}

.schedule thead th {
    border-bottom: 1px solid var(--slate-200);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--slate-500);
}

.schedule tbody tr {
    border-bottom: 1px solid var(--slate-100);
}

.schedule tbody th {
    font-weight: 700;
    color: var(--brand-950);
    white-space: nowrap;
}

.schedule tbody td {
    color: var(--slate-600);
    white-space: nowrap;
}

.schedule__section td {
    padding-top: 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--slate-500);
}

.schedule__note {
    border-bottom: 0 !important;
}

.schedule__note td {
    padding-top: 0.5rem;
    font-size: 0.75rem;
    color: var(--slate-500);
}

/* --- Galerie ------------------------------------------------------------- */

.gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-top: 2.5rem;
}

.gallery img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
}

/* --- Unterseiten: Kopf und Fließtext ------------------------------------- */

.page-head {
    padding: calc(var(--header-height) + 3rem) 0 2.5rem;
    border-bottom: 1px solid var(--slate-100);
}

.page-head__title {
    margin-top: 0.5rem;
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--brand-950);
}

.page-head__lead {
    max-width: 42rem;
    margin-top: 1rem;
    color: var(--slate-600);
}

.prose {
    color: var(--slate-600);
    font-size: 0.9375rem;
}

.prose--spaced {
    margin-top: 2.5rem;
}

.prose p + p,
.prose ul {
    margin-top: 1rem;
}

.prose h2 {
    margin-top: 2rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--brand-950);
}

.prose h3 {
    margin-top: 1.75rem;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--brand-950);
}

.prose h2 + p,
.prose h3 + p {
    margin-top: 0.75rem;
}

.prose ul {
    list-style: disc;
    padding-left: 1.5rem;
}

.prose li + li {
    margin-top: 0.25rem;
}

.prose a {
    color: var(--brand-700);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.prose strong {
    color: var(--brand-950);
}

.prose__stand {
    margin-top: 2.5rem;
    font-size: 0.875rem;
    color: var(--slate-500);
}

/* --- Leistungen ---------------------------------------------------------- */

.services > .service + .service {
    border-top: 1px solid var(--slate-100);
}

.service {
    display: grid;
    gap: 1.5rem;
    padding: 3rem 0;
    align-items: start;
}

.service__img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
}

.service__text h2 {
    margin-top: 0;
}

.service__text h2 + p {
    margin-top: 1rem;
}

/* --- Termin & Kontakt ---------------------------------------------------- */

.contact-grid {
    display: grid;
    gap: 1.25rem;
    align-items: start;
}

.contact {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
    background-color: var(--white);
    text-decoration: none;
    transition: border-color 0.2s;
}

a.contact:hover {
    border-color: var(--brand-100);
}

.contact__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    flex: none;
    border-radius: 0.75rem;
    background-color: var(--brand-50);
    color: var(--brand-800);
}

.contact__icon .icon {
    width: 1.5rem;
    height: 1.5rem;
}

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

.contact__label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--slate-500);
}

.contact__value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--brand-950);
}

.contact__value--small {
    font-size: 1rem;
    line-height: 1.35;
}

.contact__meta {
    font-size: 0.875rem;
    color: var(--slate-600);
}

.contact__link {
    margin-top: 0.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent);
}

.contact--static .table-scroll {
    margin-top: 0.5rem;
}

.map {
    width: 100%;
    height: 400px;
    background-color: var(--brand-50);
}

/* --- Fehlerseite --------------------------------------------------------- */

.error {
    padding: calc(var(--header-height) + 4rem) 0 4rem;
}

.error__inner {
    text-align: center;
}

.error__code {
    font-family: var(--font-display);
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    color: var(--brand-800);
}

.error__title {
    margin-top: 0.5rem;
    font-size: 1.5rem;
    font-weight: 700;
}

.error__text {
    max-width: 30rem;
    margin: 1rem auto 2rem;
    color: var(--slate-600);
}

/* --- Fußbereich ---------------------------------------------------------- */

.site-footer {
    background-color: var(--brand-950);
    color: var(--white);
}

.site-footer__grid {
    display: grid;
    gap: 2rem;
    max-width: 72rem;
    margin: 0 auto;
    padding: 3rem 1rem;
}

.wordmark__logo--footer {
    display: inline-block;
    font-size: 1.875rem;
}

.site-footer__claim {
    margin-top: 1rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.55);
}

.site-footer__doctors {
    margin-top: 0.75rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
}

.site-footer__heading {
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.55);
}

.site-footer__list {
    display: grid;
    gap: 0.5rem;
    margin-top: 1rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
}

.site-footer__list a {
    text-decoration: none;
    transition: color 0.2s;
}

.site-footer__list a:hover {
    color: var(--white);
    text-decoration: underline;
}

.site-footer__list--contact li {
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
}

.site-footer__list--contact .icon {
    margin-top: 0.2rem;
    width: 1rem;
    height: 1rem;
    color: rgba(255, 255, 255, 0.5);
}

.site-footer__bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    max-width: 72rem;
    margin: 0 auto;
    padding: 1.5rem 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.35);
}

.site-footer__bottom nav {
    display: flex;
    gap: 1rem;
}

.site-footer__bottom a {
    color: rgba(255, 255, 255, 0.55);
    text-decoration: none;
}

.site-footer__bottom a:hover {
    color: var(--white);
}

/* --- Animation ----------------------------------------------------------- */

@keyframes fade-up {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

.fade-up {
    animation: fade-up 0.7s ease-out both;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    .fade-up {
        animation: none;
    }
}

/* --- Breakpoints --------------------------------------------------------- */

@media (min-width: 640px) {
    .wrap,
    .site-header__bar,
    .nav--mobile,
    .site-footer__grid,
    .site-footer__bottom {
        padding-inline: 1.5rem;
    }

    .hero {
        padding-inline: 1.5rem;
        padding-top: calc(var(--header-height) + 4rem);
    }

    .wordmark__logo { font-size: 1.875rem; }
    .wordmark__claim { display: block; }

    .hero__title { font-size: 3rem; }
    .hero__lead { font-size: 1.125rem; }

    .doctor { gap: 1.25rem; padding: 1.25rem; }
    .doctor__img { width: 7rem; height: 8rem; }
    .doctor__name { font-size: 1.25rem; }

    .section { padding: 5rem 0; }
    .section__title { font-size: 2.25rem; }
    .page-head__title { font-size: 3rem; }
    .page-head__lead { font-size: 1.125rem; }

    .prose { font-size: 1rem; }
    .prose h2 { font-size: 1.875rem; }

    .gallery { gap: 1rem; }

    .site-footer__grid { grid-template-columns: repeat(3, 1fr); }

    .site-footer__bottom {
        flex-direction: row;
        justify-content: space-between;
    }

    .error__code { font-size: 6rem; }
    .error__title { font-size: 1.875rem; }
}

@media (min-width: 768px) {
    .nav--desktop { display: flex; }
    .nav-toggle { display: none; }
    .nav-mobile { display: none; }

    .doctors {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.25rem;
        margin-top: 3rem;
    }

    .service {
        grid-template-columns: repeat(2, 1fr);
        gap: 3rem;
        padding: 4rem 0;
    }

    .service--reverse .service__img {
        order: 2;
    }

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

@media (min-width: 1024px) {
    .hero__title { font-size: 3.75rem; }
    .gallery { grid-template-columns: repeat(3, 1fr); }
}
