/* ============================================================
   PAYANGAN HOSPITAL — HOMEPAGE REDESIGN LAYER
   Loaded only by index.html. Overrides the base design system
   to give the homepage a cleaner, calmer, more modern rhythm.

   Palette discipline: the existing teal (--primary) is the only
   brand hue. Amber (--secondary) is used sparingly as an accent.
   ============================================================ */

/* ------------------------------------------------------------
   0. TOKENS (additions + fixes)
   ------------------------------------------------------------ */
:root {
    /* Previously undefined — .section-xl resolved to padding:0 */
    --space-32: 112px;

    /* Slightly tighter, calmer rhythm than the legacy scale */
    --rhythm: clamp(56px, 7vw, 104px);

    --ink: #0b1f2a;
    --ink-soft: #4a5f6b;
    --hairline: #e2ebf0;
    --surface: #f6fafb;
    --surface-2: #eef6f8;
    --brand-deep: #0b3d4c;
    --brand-mid: #0e6d80;
}

/* ------------------------------------------------------------
   1. BASE / TYPOGRAPHY
   ------------------------------------------------------------ */
body {
    font-size: 17px;
    line-height: 1.65;
    color: var(--ink);
    background: #fff;
}

h1, h2, h3, h4 {
    color: var(--ink);
    letter-spacing: -0.015em;
    text-wrap: balance;
}

p { text-wrap: pretty; }

/* Consistent, comfortable section rhythm */
.section,
.section-lg,
.section-xl {
    padding: var(--rhythm) 0;
}

.section-label {
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    color: var(--brand-mid);
    margin-bottom: var(--space-3);
}

.section-title {
    font-size: clamp(1.75rem, 3.6vw, 2.6rem);
    font-weight: 700;
    line-height: 1.18;
    letter-spacing: -0.02em;
    margin-bottom: var(--space-3);
}

.section-title span { color: var(--brand-mid); }

.section-subtitle {
    font-size: 1.05rem;
    color: var(--ink-soft);
    max-width: 640px;
}

.section-header { margin-bottom: clamp(32px, 4vw, 56px); }

/* Keyboard focus — visible on every interactive element */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
    outline: 3px solid var(--primary);
    outline-offset: 3px;
    border-radius: 6px;
}

.skip-link {
    position: absolute;
    left: 16px;
    top: -60px;
    z-index: 2000;
    background: #fff;
    color: var(--brand-deep);
    padding: 12px 20px;
    border-radius: 10px;
    font-weight: 700;
    box-shadow: var(--shadow-lg);
    transition: top 0.2s ease;
}

.skip-link:focus { top: 16px; }

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

/* ------------------------------------------------------------
   2. BUTTONS — comfortable tap targets, no flashy fills
   ------------------------------------------------------------ */
.btn-appointment,
.slide-btn,
.hero-btn-primary,
.hero-btn-secondary,
.news-view-all-btn {
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 26px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.98rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.btn-appointment {
    background: var(--brand-deep);
    color: #fff;
    box-shadow: 0 8px 22px rgba(11, 61, 76, 0.22);
}

.btn-appointment:hover {
    background: #072a35;
    transform: translateY(-2px);
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 14px 26px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.98rem;
    background: transparent;
    color: var(--brand-deep);
    border: 1.5px solid var(--hairline);
    transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.btn-ghost:hover {
    border-color: var(--brand-mid);
    background: var(--surface);
    transform: translateY(-2px);
}

/* On the white header the brand wordmark inherited the light brand teal
   (#0891b2), which only reaches 3.7:1 against white — below WCAG AA for
   its 13.6px size. Deepen it for the homepage header. */
.header .brand-title {
    color: var(--brand-deep);
}

.header .brand-tagline {
    color: var(--ink-soft);
}

.logo {
    text-decoration: none;
}

.header .logo img,
.footer .logo img {
    flex: 0 0 auto;
}

/* ------------------------------------------------------------
   3. ANNOUNCEMENT BAR
   ------------------------------------------------------------ */
.announcement-bar {
    background: var(--brand-deep);
    color: #e8f4f7;
    font-size: 0.88rem;
    padding: 10px 0;
}

/* ------------------------------------------------------------
   4. HEADER / NAVIGATION
   ------------------------------------------------------------ */
.header {
    background: #fff;
    border-bottom: 1px solid var(--hairline);
}

.header-inner {
    min-height: 76px;
    gap: var(--space-6);
}

/* Solid white header from the start — over a photo hero the
   transparent variant made the logo and nav unreadable. */
.header.transparent {
    background: #fff;
    box-shadow: none;
    border-bottom: 1px solid var(--hairline);
}

.header.scrolled {
    background: #fff;
    box-shadow: 0 8px 30px rgba(11, 61, 76, 0.08);
}

.header .nav-link,
.header .nav-link-premium {
    color: var(--ink);
    font-size: 0.95rem;
    font-weight: 500;
    padding: 10px 4px;
    position: relative;
}

.header .nav-link::after,
.header .nav-link-premium::after {
    content: '';
    position: absolute;
    left: 4px;
    right: 4px;
    bottom: 2px;
    height: 2px;
    background: var(--brand-mid);
    transform: scaleX(0);
    transition: transform 0.22s ease;
    border-radius: 2px;
}

.header .nav-link:hover,
.header .nav-link-premium:hover { color: var(--brand-deep); }

.header .nav-link:hover::after,
.header .nav-link-premium:hover::after,
.header .nav-link.active::after,
.header .nav-link-premium.active::after { transform: scaleX(1); }

.header .nav-link.active,
.header .nav-link-premium.active { color: var(--brand-deep); font-weight: 700; }

.header .nav-dropdown .fas.fa-chevron-down { font-size: 0.65rem; }

.mega-menu {
    border: 1px solid var(--hairline);
    border-radius: 14px;
    box-shadow: 0 18px 44px rgba(11, 61, 76, 0.12);
    padding: 10px;
}

.mega-menu-content a {
    border-radius: 10px;
    padding: 10px 12px;
    color: var(--ink);
    font-size: 0.93rem;
}

.mega-menu-content a:hover { background: var(--surface-2); color: var(--brand-deep); }
.mega-menu-content a i { color: var(--brand-mid); }

/* Language switch as a real control */
.lang-switch {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-height: 40px;
    padding: 0 12px;
    border: 1px solid var(--hairline);
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
}

.lang-switch span { color: var(--ink-soft); font-size: 0.85rem; font-weight: 600; }
.lang-switch span.active { color: var(--brand-deep); font-weight: 800; }

/* Header emergency CTA */
.btn-emergency {
    background: #0f3b4a;
    color: #fff;
    min-height: 44px;
    padding: 0 20px;
    border-radius: 999px;
    font-size: 0.92rem;
    font-weight: 600;
    box-shadow: none;
}

.btn-emergency:hover { background: #0a2b36; }

.menu-toggle {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    border: 1px solid var(--hairline);
    padding: 0;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex-direction: column;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--brand-deep);
    border-radius: 2px;
    transition: transform 0.22s ease, opacity 0.22s ease;
}

/* Mobile drawer */
.mobile-menu {
    background: #fff;
    padding-top: 0;
}

.mobile-menu.active { display: block; }

.mobile-menu-header {
    border-bottom: 1px solid var(--hairline);
    padding: 16px 20px;
}

.mobile-menu-close {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--hairline);
    border-radius: 12px;
    color: var(--brand-deep);
    font-size: 1.05rem;
}

.mobile-nav {
    padding: 8px 20px 16px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2px;
    max-height: calc(100vh - 260px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.mobile-nav-link {
    min-height: 48px;
    display: flex;
    align-items: center;
    padding: 0 12px;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--ink);
}

.mobile-nav-link:hover,
.mobile-nav-link:active { background: var(--surface-2); color: var(--brand-deep); }

.mobile-menu-footer {
    padding: 16px 20px calc(16px + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid var(--hairline);
}

.mobile-menu-footer .btn-emergency { width: 100%; }

/* ------------------------------------------------------------
   5. HERO
   ------------------------------------------------------------ */
.hero-slider {
    height: min(88vh, 760px);
    min-height: 520px;
}

.slide {
    align-items: center;
    justify-content: flex-start;
    padding: 0 clamp(20px, 5vw, 80px);
}

/* One consistent brand scrim over every slide photo, replacing
   the old multi-colour gradients (purple / magenta / brown). */
.slide::after {
    background:
        linear-gradient(100deg,
            rgba(6, 42, 54, 0.95) 0%,
            rgba(11, 77, 96, 0.90) 42%,
            rgba(11, 61, 76, 0.62) 78%,
            rgba(11, 61, 76, 0.55) 100%);
}

.slide-content {
    width: 100%;
    max-width: 760px;
    margin: 0;
    text-align: left;
}

.slide-badge {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(8px);
    padding: 8px 18px;
    font-size: 0.82rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 20px;
}

.slide-badge i { color: #7fd7e6; }

.slide-title {
    font-size: clamp(1.9rem, 4.4vw, 3.1rem);
    font-weight: 700;
    line-height: 1.14;
    letter-spacing: -0.025em;
    color: #fff;
    margin-bottom: 16px;
    max-width: 18ch;
}

.slide-title span {
    color: #8fdfec;
}

.slide-title span::after { display: none; }

.slide-subtitle {
    font-size: clamp(1rem, 1.6vw, 1.13rem);
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.65;
    max-width: 56ch;
    margin: 0 0 28px;
}

.slide-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.slide-btn-primary {
    background: #fff;
    color: var(--brand-deep);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
}

.slide-btn-primary:hover { transform: translateY(-2px); }

.slide-btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
}

.slide-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #fff;
}

/* Slider controls */
.slider-nav { bottom: 108px; gap: var(--space-4); }

.slider-prev, .slider-next {
    width: 46px;
    height: 46px;
    border-color: rgba(255, 255, 255, 0.35);
    background: rgba(6, 42, 54, 0.4);
}

/* Slider dots keep a small visual mark but a 24px hit area for touch. */
.dot {
    position: relative;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 0;
    background: transparent;
    border-radius: 50%;
}

.dot::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 9px;
    height: 9px;
    margin: -4.5px 0 0 -4.5px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transition: background-color 0.25s ease, width 0.25s ease, height 0.25s ease, margin 0.25s ease;
}

.dot:hover::after,
.dot.active::after {
    background: #8fdfec;
    width: 13px;
    height: 13px;
    margin: -6.5px 0 0 -6.5px;
}

.slider-dots { gap: 4px; }

/* Hero stat strip — quiet, informative, not promotional */
.slider-stats {
    background: #fff;
    border-top: 1px solid var(--hairline);
    backdrop-filter: none;
    padding: 18px clamp(20px, 5vw, 80px);
    gap: clamp(16px, 3vw, 40px);
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--brand-deep);
    line-height: 1.1;
}

.stat-number span { font-size: 1.05rem; color: var(--brand-mid); }

.stat-label {
    font-size: 0.74rem;
    color: var(--ink-soft);
    letter-spacing: 0.08em;
    margin-top: 2px;
}

.stat-divider { background: var(--hairline); height: 34px; }

/* ------------------------------------------------------------
   6. QUICK ACCESS
   ------------------------------------------------------------ */
.quick-section {
    background: #fff;
    padding: clamp(32px, 4.5vw, 56px) 0;
    border-bottom: 1px solid var(--hairline);
}

.quick-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
}

.quick-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    min-height: 112px;
    padding: 18px 16px;
    background: var(--surface);
    border: 1px solid transparent;
    border-radius: 16px;
    color: var(--ink);
    transition: background-color 0.22s ease, border-color 0.22s ease, transform 0.22s ease;
}

.quick-card:hover {
    background: #fff;
    border-color: var(--hairline);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.quick-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #fff;
    border: 1px solid var(--hairline);
    color: var(--brand-mid);
    font-size: 1.1rem;
    flex: 0 0 auto;
}

.quick-label {
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.25;
}

.quick-note {
    font-size: 0.8rem;
    color: var(--ink-soft);
    line-height: 1.35;
}

/* ------------------------------------------------------------
   7. FEATURED SERVICE (HD) + SERVICE CARDS
   ------------------------------------------------------------ */
.featured-section { background: var(--surface); }

.featured-card {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 0;
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 18px 48px rgba(11, 61, 76, 0.08);
}

.featured-body {
    padding: clamp(28px, 4vw, 52px);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.featured-title {
    font-size: clamp(1.5rem, 3vw, 2.15rem);
    font-weight: 700;
    line-height: 1.18;
    letter-spacing: -0.02em;
    margin: 14px 0 16px;
}

.featured-text {
    font-size: 1.04rem;
    color: var(--ink-soft);
    line-height: 1.7;
    margin-bottom: 26px;
    max-width: 52ch;
}

.featured-figure {
    position: relative;
    min-height: 320px;
    background: var(--surface-2);
}

.featured-figure img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.services-section { background: #fff; }

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

.service-card {
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: 18px;
    padding: 26px 24px 22px;
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.service-card::before { display: none; }

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

.service-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: var(--surface-2);
    color: var(--brand-mid);
    font-size: 1.25rem;
    margin-bottom: 18px;
}

.service-title {
    font-size: 1.12rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.service-text {
    font-size: 0.95rem;
    color: var(--ink-soft);
    line-height: 1.6;
    margin-bottom: 16px;
}

.service-link {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--brand-mid);
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* ------------------------------------------------------------
   8. ROOM AVAILABILITY (kamar)
   ------------------------------------------------------------ */
.rooms-section {
    background: var(--surface);
}

.rooms-shell {
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: 22px;
    padding: clamp(24px, 3.5vw, 40px);
}

.rooms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 12px;
    margin-top: 26px;
}

.room-tile {
    padding: 18px 18px 16px;
    border: 1px solid var(--hairline);
    border-radius: 16px;
    background: #fff;
}

.room-tile-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.room-class {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--ink);
}

.room-badge {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 999px;
    white-space: nowrap;
}

.room-badge.is-available { background: #e7f7f0; color: #0a6b47; }
.room-badge.is-limited  { background: #fdf3e2; color: #8a5a06; }
.room-badge.is-full     { background: #fdecec; color: #9b2c2c; }

.room-count {
    font-size: 1.7rem;
    font-weight: 700;
    line-height: 1.1;
    color: var(--brand-deep);
}

.room-count small {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--ink-soft);
}

.room-bar {
    height: 6px;
    border-radius: 999px;
    background: var(--surface-2);
    margin-top: 14px;
    overflow: hidden;
}

.room-bar span {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: var(--brand-mid);
}

.rooms-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--hairline);
    font-size: 0.88rem;
    color: var(--ink-soft);
}

.rooms-note {
    margin-top: 14px;
    font-size: 0.85rem;
    color: var(--ink-soft);
}

/* ------------------------------------------------------------
   8b. RUNNING QUEUE (antrean berjalan)
   Shares the rooms shell language: same radius, hairline and
   tokens, so the two live blocks read as one zone.
   ------------------------------------------------------------ */
.queue-section {
    background: #fff;
}

.queue-shell {
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: 22px;
    padding: clamp(24px, 3.5vw, 40px);
}

/* Shared by both live blocks: state line + freshness timestamp. */
.queue-statebar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px 16px;
    margin-top: 20px;
    min-height: 26px;
}

.queue-state {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1.4;
}

.queue-state:empty { display: none; }

.queue-state.is-stale {
    background: #fdf3e2;
    color: #8a5a06;
    border-radius: 999px;
    padding: 5px 12px;
}

.queue-state.is-unavailable {
    background: #fdecec;
    color: #9b2c2c;
    border-radius: 999px;
    padding: 5px 12px;
}

.queue-updated {
    font-size: 0.82rem;
    color: var(--ink-soft);
    font-variant-numeric: tabular-nums;
}

.queue-updated:empty { display: none; }

/* Reserve height before data arrives so the page does not jump. */
.queue-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 18px;
    min-height: 116px;
}

.queue-card {
    display: flex;
    flex-direction: column;
    padding: 16px 16px 14px;
    border: 1px solid var(--hairline);
    border-radius: 16px;
    background: #fff;
    min-width: 0;
}

.queue-card-head {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.queue-poli-icon {
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    border-radius: 9px;
    display: grid;
    place-items: center;
    background: var(--surface-2);
    color: var(--brand-mid);
    font-size: 0.82rem;
}

.queue-poli {
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--ink);
    /* Two-line clamp keeps uneven poli names from breaking the grid. */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.queue-number {
    margin-top: 10px;
    font-size: 2.35rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
    color: var(--brand-deep);
}

.queue-number-label {
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--ink-soft);
    margin-top: 2px;
}

.queue-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: auto;
    padding-top: 12px;
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--ink-soft);
}

/* Status is carried by an icon + text, never by colour alone. */
.queue-status .queue-status-dot {
    flex: 0 0 auto;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    border: 2px solid currentColor;
    background: transparent;
}

.queue-status.is-ready    { color: #0a6b47; }
.queue-status.is-running  { color: #0a6b47; }
.queue-status.is-delayed  { color: #8a5a06; }
.queue-status.is-waiting  { color: #4a5f6b; }
.queue-status.is-closed   { color: #6b7a83; }

.queue-status.is-ready .queue-status-dot,
.queue-status.is-running .queue-status-dot { background: currentColor; }

.queue-empty {
    margin: 0;
    padding: 22px 20px;
    border: 1px dashed var(--hairline);
    border-radius: 16px;
    background: var(--surface);
    font-size: 0.9rem;
    color: var(--ink-soft);
    text-align: center;
}

.queue-note {
    margin-top: 14px;
    font-size: 0.85rem;
    color: var(--ink-soft);
}

/* ------------------------------------------------------------
   9. SAMBUTAN (director welcome)
   ------------------------------------------------------------ */
.director-section { background: #fff; }

.director-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
    gap: clamp(32px, 5vw, 72px);
    align-items: center;
}

.director-image-wrapper { max-width: 520px; }

.director-image {
    max-width: 100%;
    border-radius: 22px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    box-shadow: 0 24px 60px rgba(11, 61, 76, 0.14);
    transition: transform 0.35s ease;
}

.director-content { padding-left: 0; }

.director-quote-mark {
    font-size: 4rem;
    line-height: 0.8;
    color: var(--primary-100);
    margin-bottom: 8px;
}

.director-message {
    font-size: 1.04rem;
    line-height: 1.8;
    color: var(--ink-soft);
}

.director-name {
    font-size: 1.08rem;
    font-weight: 700;
    color: var(--ink);
}

.director-title {
    font-size: 0.9rem;
    color: var(--brand-mid);
    font-weight: 600;
}

/* ------------------------------------------------------------
   10. KEUNGGULAN / WHY
   ------------------------------------------------------------ */
.why-section {
    background: var(--brand-deep);
    padding: var(--rhythm) 0;
}

.why-section::before,
.why-section::after { display: none; }

.why-section .section-title { color: #fff; }
.why-section .section-title span { color: #8fdfec; }
.why-section .section-subtitle { color: rgba(255, 255, 255, 0.75); }
.why-section .section-label { color: #8fdfec; }
.why-section .section-label::before { background: #8fdfec; }

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

.why-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    padding: 28px 24px;
}

.why-card::before { display: none; }

.why-card:hover {
    background: rgba(255, 255, 255, 0.09);
    transform: translateY(-4px);
    box-shadow: none;
}

.why-card-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.1);
    color: #8fdfec;
    font-size: 1.25rem;
    margin-bottom: 18px;
}

.why-card-icon::after { display: none; }

.why-card-title { color: #fff; font-size: 1.08rem; font-weight: 700; }

.why-card-text { color: rgba(255, 255, 255, 0.72); font-size: 0.94rem; line-height: 1.6; }

/* ------------------------------------------------------------
   11. FASILITAS
   ------------------------------------------------------------ */
.facilities-section { background: #fff; }

.facilities-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 210px;
    gap: 14px;
}

.facility-card {
    border-radius: 18px;
    aspect-ratio: auto;
    box-shadow: var(--shadow-sm);
}

.facility-card:first-child { grid-column: span 2; grid-row: span 2; }

.facility-overlay {
    background: linear-gradient(to top, rgba(6, 42, 54, 0.9) 0%, rgba(6, 42, 54, 0.15) 60%, transparent 100%);
    padding: 18px;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    gap: 2px;
}

.facility-name {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
}

.facility-note {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
}

.facility-card:hover { box-shadow: var(--shadow-lg); }

/* ------------------------------------------------------------
   12. BERITA
   ------------------------------------------------------------ */
.news-section { background: var(--surface); }

.news-slider-wrapper { position: relative; }

.news-slider {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 36px) / 3);
    gap: 18px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding-bottom: 6px;
}

.news-slider::-webkit-scrollbar { display: none; }

.news-card {
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: 18px;
    overflow: hidden;
    scroll-snap-align: start;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.news-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.news-card-image { aspect-ratio: 16 / 10; overflow: hidden; }

.news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-card-content { padding: 20px 20px 22px; }

.news-card-date {
    font-size: 0.8rem;
    color: var(--ink-soft);
    background: none;
    padding: 0;
    display: inline-flex;
    gap: 6px;
    align-items: center;
}

.news-card-category {
    display: inline-block;
    margin: 10px 0 8px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--brand-mid);
    background: var(--surface-2);
    padding: 4px 10px;
    border-radius: 999px;
}

.news-card-title { font-size: 1.05rem; line-height: 1.35; margin-bottom: 8px; }

.news-card-excerpt {
    font-size: 0.9rem;
    color: var(--ink-soft);
    line-height: 1.55;
    margin-bottom: 14px;
}

.news-card-footer {
    border-top: 1px solid var(--hairline);
    padding-top: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.8rem;
    color: var(--ink-soft);
}

.news-card-author { display: inline-flex; align-items: center; gap: 8px; }

.news-card-avatar {
    width: 26px;
    height: 26px;
    font-size: 0.7rem;
    border-radius: 50%;
}

.news-card-read-time { display: inline-flex; align-items: center; gap: 6px; }

.news-slider-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--hairline);
    background: #fff;
    color: var(--brand-deep);
    top: 38%;
    box-shadow: var(--shadow-md);
}

.news-slider-btn:hover { background: var(--brand-deep); color: #fff; border-color: var(--brand-deep); }

.news-slider-dots { justify-content: center; margin-top: 20px; }

.news-dot {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    background: #c6d7de;
}

.news-dot.active, .news-dot:hover { background: var(--brand-mid); }

.news-view-all-btn {
    background: var(--brand-deep);
    color: #fff;
    box-shadow: none;
}

.news-view-all-btn:hover { background: #072a35; transform: translateY(-2px); }

/* ------------------------------------------------------------
   13. GALERI (compact)
   ------------------------------------------------------------ */
.gallery-section {
    background: var(--brand-deep);
    padding: var(--rhythm) 0;
}

.gallery-section .section-label { color: #8fdfec; }
.gallery-section .section-label::before { background: #8fdfec; }
.gallery-section .section-title { color: #fff; }
.gallery-section .section-title span { color: #8fdfec; }
.gallery-section .section-subtitle { color: rgba(255, 255, 255, 0.72); }

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-auto-rows: 150px;
    gap: 12px;
}

.gallery-item {
    border-radius: 14px;
    overflow: hidden;
    position: relative;
}

.gallery-item:nth-child(1) { grid-column: span 2; grid-row: span 2; }
.gallery-item:nth-child(2) { grid-column: span 2; }
.gallery-item:nth-child(3) { grid-column: span 1; }
.gallery-item:nth-child(4) { grid-column: span 1; }
.gallery-item:nth-child(5) { grid-column: span 1; }
.gallery-item:nth-child(6) { grid-column: span 1; }

.gallery-item img { width: 100%; height: 100%; object-fit: cover; }

.gallery-overlay {
    background: rgba(6, 42, 54, 0.55);
    opacity: 0;
    transition: opacity 0.22s ease;
}

.gallery-item:hover .gallery-overlay { opacity: 1; }

.gallery-cta { text-align: center; margin-top: 32px; }

.gallery-cta a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 14px 26px;
    border-radius: 999px;
    background: #fff;
    color: var(--brand-deep);
    font-weight: 600;
}

.gallery-cta a:hover { background: #8fdfec; }

/* ------------------------------------------------------------
   14. CLOSING CTA + CONTACT
   ------------------------------------------------------------ */
.closing-section {
    background: #fff;
    padding: var(--rhythm) 0;
}

.closing-shell {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 0;
    background: var(--brand-deep);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(11, 61, 76, 0.18);
}

.closing-primary {
    padding: clamp(30px, 4.5vw, 56px);
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.closing-primary .section-label { color: #8fdfec; }
.closing-primary .section-label::before { background: #8fdfec; }

.closing-title {
    font-size: clamp(1.6rem, 3.2vw, 2.3rem);
    font-weight: 700;
    line-height: 1.18;
    color: #fff;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.closing-text {
    color: rgba(255, 255, 255, 0.78);
    font-size: 1.04rem;
    line-height: 1.7;
    margin-bottom: 28px;
    max-width: 46ch;
}

.closing-phone {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 14px 24px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: #fff;
    font-weight: 700;
    font-size: 1.15rem;
    min-height: 60px;
}

.closing-phone i { font-size: 1.3rem; color: #8fdfec; }

.closing-phone small {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.68);
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.closing-secondary {
    background: #fff;
    padding: clamp(28px, 4vw, 44px);
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-row {
    display: flex;
    gap: 16px;
    padding: 18px 0;
    border-bottom: 1px solid var(--hairline);
}

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

.info-row:first-child { padding-top: 0; }

.info-icon {
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    border-radius: 12px;
    background: var(--surface-2);
    color: var(--brand-mid);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.info-label {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink-soft);
    margin-bottom: 4px;
}

.info-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ink);
    line-height: 1.5;
}

/* Standalone links get a comfortable tap height (inline links inside a
   sentence are exempt, these are not). */
.info-value a {
    display: inline-block;
    min-height: 32px;
    line-height: 32px;
    color: var(--brand-deep);
}

.info-value a:hover { text-decoration: underline; }

/* ------------------------------------------------------------
   15. FOOTER (compact, 5 columns)
   ------------------------------------------------------------ */
.footer {
    background: #062833;
    color: rgba(255, 255, 255, 0.72);
    padding: clamp(44px, 5vw, 64px) 0 28px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.6fr repeat(4, 1fr);
    gap: clamp(24px, 3vw, 44px);
    margin-bottom: 36px;
}

.footer-brand { max-width: 340px; }

.footer-desc {
    font-size: 0.9rem;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.62);
    margin: 14px 0 18px;
}

.footer-column h3 {
    color: #fff;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 14px;
}

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

.footer-links a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 34px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.62);
}

.footer-links a:hover { color: #8fdfec; }

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding-top: 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 0.85rem;
}

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

.footer-links-bottom a {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 10px;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.6);
}

.footer-links-bottom a:hover { color: #8fdfec; background: rgba(255, 255, 255, 0.07); }

.footer-social { display: flex; gap: 8px; }

.footer-social a {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: rgba(255, 255, 255, 0.7);
}

.footer-social a:hover { background: rgba(255, 255, 255, 0.1); color: #8fdfec; }

/* ------------------------------------------------------------
   16. REVEAL ANIMATION (subtle)
   ------------------------------------------------------------ */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ------------------------------------------------------------
   17. RESPONSIVE — mobile-first hardening
   ------------------------------------------------------------ */
@media (max-width: 1200px) {
    .quick-grid { grid-template-columns: repeat(3, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
}

/* The base stylesheet only collapsed the desktop nav at 992px, which left
   the nav + header actions overflowing the header between roughly 992px
   and 1150px. Hand over to the drawer earlier so nothing is ever clipped. */
@media (max-width: 1180px) {
    .nav, .header-actions { display: none; }
    .menu-toggle { display: flex; }
    .mobile-menu { display: block; }
}

/* Comfortable but tighter spacing for the medium desktop range. */
@media (min-width: 1181px) and (max-width: 1340px) {
    .header-inner { gap: var(--space-4); }
    .header .nav-link,
    .header .nav-link-premium { font-size: 0.88rem; }
    .logo-text { margin-left: 10px; }
    .btn-emergency { padding: 0 14px; font-size: 0.85rem; }
    .lang-switch { padding: 0 9px; }
}

@media (max-width: 1024px) {
    .featured-card { grid-template-columns: 1fr; }
    .featured-figure { min-height: 260px; order: -1; }
    .director-grid { grid-template-columns: 1fr; }
    .director-image-wrapper { max-width: 100%; margin: 0; }
    .director-content { text-align: left; }
    .director-signature { display: block; }
    .why-grid { grid-template-columns: repeat(2, 1fr); }
    .closing-shell { grid-template-columns: 1fr; }
    .facilities-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 190px; }
    .facility-card:first-child { grid-column: span 2; grid-row: span 1; }
    .gallery-grid { grid-template-columns: repeat(4, 1fr); }
    .gallery-item:nth-child(1) { grid-column: span 2; grid-row: span 2; }
    .news-slider { grid-auto-columns: calc((100% - 18px) / 2); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    body { font-size: 16px; }

    .hero-slider { height: auto; min-height: 0; }
    .slide { min-height: 520px; padding: 88px 20px 132px; }
    .slide-title { max-width: none; }
    .slide-actions { flex-direction: column; align-items: stretch; }
    .slide-actions .slide-btn { width: 100%; }
    .slider-nav { bottom: 118px; }
    .slider-stats { gap: 12px; padding: 16px 20px; }
    .stat-item { flex: 1 1 40%; }
    .stat-number { font-size: 1.25rem; }

    .quick-grid { grid-template-columns: repeat(2, 1fr); }
    .quick-card { min-height: 104px; }

    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .facilities-grid { grid-template-columns: 1fr; grid-auto-rows: 210px; }
    .facility-card:first-child { grid-column: span 1; grid-row: span 1; }

    .gallery-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 130px; }
    .gallery-item:nth-child(1) { grid-column: span 2; grid-row: span 1; }
    .gallery-item:nth-child(2) { grid-column: span 1; }
    .gallery-item:nth-child(3) { grid-column: span 1; }
    .gallery-item:nth-child(4),
    .gallery-item:nth-child(5),
    .gallery-item:nth-child(6) { grid-column: span 1; }

    .news-slider { grid-auto-columns: 100%; }
    .news-slider-btn { display: none; }

    .mobile-nav { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .footer-links-bottom { justify-content: center; }
}

@media (max-width: 560px) {
    .quick-grid { grid-template-columns: 1fr; }
    .quick-card { flex-direction: row; align-items: center; min-height: 0; }
    .services-grid { grid-template-columns: 1fr; }
    .rooms-grid { grid-template-columns: 1fr; }
    .queue-grid { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
    .why-grid { grid-template-columns: 1fr; }
}

/* Nine 24px dots plus two arrows no longer fit beside each other on a
   320px screen. Tighten the gaps rather than shrinking the tap targets. */
@media (max-width: 420px) {
    .slider-nav { gap: 6px; }
    .slider-dots { gap: 2px; }
    .slider-prev, .slider-next { width: 36px; height: 36px; font-size: 0.85rem; }
}

/* Nothing may scroll sideways */
html, body { max-width: 100%; overflow-x: hidden; }

img, svg, video, iframe, table {
    max-width: 100%;
}

/* ------------------------------------------------------------
   18. MOTION / PRINT PREFERENCES
   ------------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
    .animate-on-scroll { opacity: 1; transform: none; }
}

@media print {
    .header, .announcement-bar, .mobile-menu, .slider-nav, .slider-stats,
    #mahacare-button, #mahacare-window, .skip-link { display: none !important; }
    .slide { position: static; opacity: 1; visibility: visible; height: auto; }
}