/* =========================================================
   Przedszkole pw. Aniołów Stróżów — styles.css
   Paleta: jasny błękit + biel + żółć, fonty: Playfair + Open Sans
   ========================================================= */

:root {
    --bg-base:           #EFF6FB;
    --bg-soft:           #DDEFFA;
    --bg-yellow:         #FBF4C9;
    --bg-yellow-strong:  #F6E993;
    --paper:             #FFFFFF;
    --navy:              #102A40;
    --text:              #1F3650;
    --muted:             #6B7E92;
    --blue:              #3F7DB3;
    --blue-dk:           #305F89;
    --blue-soft:         #CCE4F4;
    --footer:            #0B2334;
    --footer-text:       #5F7385;
    --footer-text-strong:#C9D4DF;

    --r-sm: 8px;
    --r-md: 18px;
    --r-lg: 28px;

    --maxw: 1280px;
}

/* Reset */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 100px; }
body {
    background: var(--bg-base);
    color: var(--text);
    font-family: 'Open Sans', system-ui, sans-serif;
    font-size: 17px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; transition: color .2s; }
button { font-family: inherit; cursor: pointer; }
ul, ol { padding: 0; margin: 0; list-style: none; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 32px; }
@media (max-width: 720px) { .wrap { padding: 0 22px; } }

/* ===== NAV ===== */
.nav {
    position: sticky; top: 0; z-index: 50;
    background: var(--paper);
    border-bottom: 1px solid #E5EEF5;
    transition: box-shadow .2s;
}
.nav.is-scrolled { box-shadow: 0 6px 18px rgba(20,40,60,.07); }
.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 108px;
    padding: 14px 0;
    gap: 24px;
}
.brand {
    display: flex; align-items: center; gap: 18px;
    color: var(--navy);
    line-height: 1.2;
}
.brand-mark {
    width: 74px; height: 74px; flex: 0 0 74px;
    position: relative;
    /* tło i zaokrąglenie używane tylko dla stanu placeholdera — patrz .brand-mark__placeholder */
}
.brand-mark img {
    width: 100%; height: 100%;
    object-fit: contain;
    display: block;
}
.brand-mark__placeholder {
    position: absolute; inset: 0;
    display: none;           /* ukryty domyślnie — odsłania się tylko gdy <img> nie wczyta się (onerror) */
    place-items: center;
    font-family: 'Open Sans', sans-serif;
    font-weight: 700;
    font-size: 12px;
    letter-spacing: .18em;
    color: var(--blue);
    background:
        repeating-linear-gradient(45deg, rgba(63,125,179,.08) 0 8px, transparent 8px 16px),
        var(--bg-soft);
    border: 1.5px dashed rgba(63,125,179,.45);
    border-radius: 14px;
}
/* When the real <img> is broken/hidden, the placeholder is forced visible inline via onerror */
.brand-text {
    font-family: 'Open Sans', sans-serif;
    font-weight: 700;
    font-size: 19px;
    color: var(--navy);
}
.brand-text span { display: block; }

.nav-links {
    display: flex;
    gap: 38px;
    align-items: center;
}
.nav-links a {
    color: var(--navy);
    font-weight: 700;
    font-size: 18px;
    transition: color .2s;
}
.nav-links a:hover { color: var(--blue); }

.burger {
    display: none;
    background: none; border: 0;
    padding: 8px;
}
.burger span {
    display: block;
    width: 24px; height: 2px;
    background: var(--navy);
    margin: 5px 0;
    transition: transform .3s, opacity .3s;
}
.burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 1080px) {
    .nav-links { display: none; }
    .burger { display: block; }
    .brand-text { font-size: 16px; }
    .brand-mark { width: 58px; height: 58px; flex-basis: 58px; }
    .nav-inner { min-height: 84px; }
}

.mobile-menu {
    position: fixed;
    inset: 84px 0 0 0;
    background: var(--paper);
    z-index: 49;
    padding: 28px;
    display: none;
    flex-direction: column;
    border-top: 1px solid #E5EEF5;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
    color: var(--navy);
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 28px;
    padding: 16px 0;
    border-bottom: 1px solid #E5EEF5;
}

/* ===== HERO ===== */
.hero { padding: 80px 0 120px; }
.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}
@media (max-width: 960px) {
    .hero-grid { grid-template-columns: 1fr; gap: 48px; }
}
.hero h1 {
    font-family: 'Playfair Display', serif;
    font-weight: 800;
    color: var(--navy);
    margin: 0 0 44px;
    font-size: clamp(48px, 6.4vw, 84px);
    line-height: 1.05;
    letter-spacing: -.01em;
}
.hero p {
    color: var(--muted);
    font-size: 18px;
    line-height: 1.65;
    max-width: 520px;
    margin: 0 0 36px;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.btn {
    display: inline-flex;
    align-items: center;
    padding: 14px 28px;
    border-radius: var(--r-sm);
    font-weight: 700;
    font-size: 15px;
    transition: background .2s, color .2s, transform .15s, box-shadow .2s;
    border: 2px solid transparent;
}
.btn-primary {
    background: var(--blue);
    color: #fff;
    box-shadow: 0 8px 20px -8px rgba(63,125,179,.55);
}
.btn-primary:hover { background: var(--navy); transform: translateY(-2px); }
.btn-ghost {
    background: transparent;
    color: var(--navy);
    border-color: rgba(16,42,64,.18);
}
.btn-ghost:hover { border-color: var(--blue); color: var(--blue); }

.hero-photo {
    width: 100%; max-width: 580px;
    aspect-ratio: 1 / 1;
    margin-left: auto;
    border-radius: 50%;
    overflow: hidden;
    background: radial-gradient(circle at 40% 30%, #7d9a4e 0%, #3f5524 60%, #22360f 100%);
    position: relative;
    box-shadow: 0 14px 36px -14px rgba(20,40,60,.2);
}

.hero-photo img,
.offer-photo img,
.patron-portrait img,
.gallery-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Placeholder treatment for any "ph" element */
.ph {
    position: absolute;
    inset: 0;
    display: grid;
    place-content: center;
    text-align: center;
    line-height: 1.6;
    color: rgba(255,255,255,.92);
    font-family: ui-monospace, monospace;
    font-size: 12px;
    letter-spacing: .14em;
    text-transform: uppercase;
    background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.06) 0 16px, transparent 16px 32px);
    padding: 24px;
}
.ph strong {
    font-size: 15px;
    display: block;
    letter-spacing: .22em;
    margin-bottom: 10px;
}

/* ===== SECTIONS ===== */
.section { padding: 110px 0; }
@media (max-width: 720px) { .section { padding: 72px 0; } }
.section-title {
    text-align: center;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: clamp(36px, 5vw, 56px);
    line-height: 1.1;
    color: var(--navy);
    margin: 0 0 32px;
    letter-spacing: -.01em;
}
.section-lede {
    max-width: 640px;
    margin: 0 auto 80px;
    text-align: center;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.75;
}

/* ===== ABOUT ===== */
.about { background: var(--paper); }
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; gap: 48px; } }
.stamp-wrap {
    width: 100%;
    max-width: 460px;
    margin: 0 auto;
    aspect-ratio: 1 / 1;
    position: relative;
    border-radius: 50%;
    overflow: hidden;
    background: var(--paper);
}
.stamp-wrap img {
    width: 100%; height: 100%;
    object-fit: contain;
    display: block;
    padding: 12px;
}
.stamp-wrap__placeholder {
    position: absolute; inset: 0;
    display: none;           /* ukryty domyślnie — pojawia się przez onerror, gdy <img> nie wczyta się */
    place-content: center;
    text-align: center;
    gap: 10px;
    color: var(--blue);
    font-family: 'Open Sans', sans-serif;
    font-weight: 700;
    letter-spacing: .22em;
    text-transform: uppercase;
    border-radius: 50%;
    border: 2px dashed rgba(63,125,179,.55);
    background:
        repeating-linear-gradient(45deg, rgba(63,125,179,.06) 0 14px, transparent 14px 28px),
        var(--bg-soft);
}
.stamp-wrap__placeholder span:first-child { font-size: 18px; color: var(--navy); }
.stamp-wrap__placeholder span:last-child {
    font-size: 12px;
    letter-spacing: .12em;
    text-transform: none;
    color: var(--muted);
    font-weight: 600;
}
.about-text p {
    color: var(--muted);
    font-size: 17.5px;
    line-height: 1.8;
    margin: 0 0 24px;
    max-width: 520px;
}
.bullet-list {
    margin: 42px 0 0;
    display: grid;
    gap: 28px;
}
.bullet-list li {
    display: flex;
    align-items: center;
    gap: 22px;
    color: var(--text);
    font-size: 17px;
    line-height: 1.5;
    max-width: 640px;
}
.b-ico {
    flex: 0 0 40px;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--blue-soft);
    color: var(--blue);
    display: grid; place-items: center;
}
.b-ico svg { width: 18px; height: 18px; }

/* ===== STATS ===== */
.stats {
    background: linear-gradient(135deg, var(--blue) 0%, var(--navy) 100%);
    color: #fff;
    padding: 70px 0;
    position: relative;
    overflow: hidden;
}
.stats::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(255,255,255,.10), transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(246,233,147,.18), transparent 50%);
    pointer-events: none;
}
.stats-grid {
    position: relative;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    text-align: center;
}
.stat-num {
    font-family: 'Playfair Display', serif;
    font-size: clamp(40px, 5vw, 64px);
    font-weight: 800;
    line-height: 1;
    display: inline-block;
}
.stat-plus {
    font-family: 'Playfair Display', serif;
    font-size: 38px;
    color: var(--bg-yellow-strong);
    margin-left: 2px;
}
.stat p {
    margin: 8px 0 0;
    opacity: .92;
    font-size: 14.5px;
}
@media (max-width: 880px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 36px; }
}

/* ===== FEATURES ===== */
.features { background: var(--bg-yellow); }
.features-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 48px 56px;
    max-width: 1100px;
    margin: 0 auto;
}
.features-row.bot {
    grid-template-columns: repeat(2, 1fr);
    max-width: 780px;
    margin-top: 80px;
}
@media (max-width: 880px) {
    .features-row,
    .features-row.bot { grid-template-columns: 1fr; max-width: 460px; gap: 64px; }
}
.feature { text-align: center; padding: 0 8px; }
.feature .ico {
    width: 84px; height: 84px;
    margin: 0 auto 32px;
    color: var(--blue);
    display: grid; place-items: center;
    position: relative;
}
.feature .ico svg { width: 64px; height: 64px; }
.feature .ico img {
    width: 100%; height: 100%;
    object-fit: contain;
    display: block;
}
.feature .ico .ico__placeholder {
    position: absolute; inset: 0;
    display: none;           /* ukryty domyślnie — odsłania się tylko gdy <img> ikony nie wczyta się */
    place-items: center;
    font-family: 'Open Sans', sans-serif;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: .22em;
    color: var(--blue);
    border-radius: 16px;
    border: 1.5px dashed rgba(63,125,179,.55);
    background:
        repeating-linear-gradient(45deg, rgba(63,125,179,.08) 0 8px, transparent 8px 16px),
        var(--bg-soft);
}
.feature h4 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 24px;
    color: var(--navy);
    margin: 0 0 28px;
    line-height: 1.25;
}
.feature p {
    color: var(--muted);
    font-size: 15.5px;
    line-height: 1.7;
    max-width: 300px;
    margin: 0 auto;
}

/* ===== OFFER ===== */
.offer { background: var(--paper); position: relative; overflow: hidden; }
.deco-blue {
    position: absolute;
    right: -200px; top: 140px;
    width: 480px; height: 480px;
    border-radius: 50%;
    background: var(--bg-soft);
    z-index: 0;
}
.deco-yellow {
    position: absolute;
    left: -140px; bottom: -80px;
    width: 340px; height: 340px;
    border-radius: 50%;
    background: var(--bg-yellow-strong);
    z-index: 0;
    opacity: .95;
}
.offer .wrap { position: relative; z-index: 1; }
.offer-grid {
    display: grid;
    grid-template-columns: 1fr 1.05fr;
    gap: 80px;
    align-items: center;
    margin-top: 80px;
}
@media (max-width: 960px) { .offer-grid { grid-template-columns: 1fr; gap: 56px; } }
.offer-photo {
    width: 100%; max-width: 540px;
    aspect-ratio: 5 / 4;
    border-radius: 18px;
    overflow: hidden;
    background: linear-gradient(135deg, #4a5d72 0%, #2c3e54 100%);
    position: relative;
    box-shadow: 0 14px 36px -16px rgba(20,40,60,.25);
}
.offer-grid .bullet-list { margin: 0; gap: 24px; }
.offer-grid .bullet-list li { font-size: 16.5px; }

/* ===== DAY PLAN ===== */
.dayplan { background: var(--bg-base); }
.timeline {
    counter-reset: step;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 1100px;
    margin: 0 auto;
}
.timeline li {
    background: var(--paper);
    padding: 28px 28px 28px 76px;
    border-radius: var(--r-md);
    box-shadow: 0 6px 18px -10px rgba(20,40,60,.15);
    position: relative;
    counter-increment: step;
    border: 1px solid #E5EEF5;
}
.timeline li::before {
    content: counter(step);
    position: absolute;
    top: 28px; left: 24px;
    width: 36px; height: 36px;
    border-radius: 50%;
    background: var(--blue);
    color: #fff;
    display: grid; place-items: center;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 16px;
}
.t-time {
    display: inline-block;
    color: var(--blue);
    font-weight: 700;
    font-size: 13px;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 4px;
}
.timeline h4 {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    color: var(--navy);
    margin: 0 0 6px;
}
.timeline p { margin: 0; color: var(--muted); font-size: 15.5px; line-height: 1.6; }

@media (max-width: 960px) { .timeline { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .timeline { grid-template-columns: 1fr; } }

/* ===== PATRON ===== */
.patron { background: var(--bg-soft); padding: 110px 0; }
.patron .quote {
    max-width: 760px;
    margin: 0 auto 96px;
    text-align: center;
    font-family: 'Open Sans', sans-serif;
    font-style: italic;
    font-size: 19px;
    color: var(--muted);
    line-height: 1.75;
}
.patron .quote::before,
.patron .quote::after { content: '"'; }
.patron-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 90px;
    align-items: center;
}
@media (max-width: 900px) { .patron-grid { grid-template-columns: 1fr; gap: 48px; } }
.patron-portrait {
    width: 100%;
    max-width: 380px;
    margin-left: auto;
    aspect-ratio: 1 / 1;
    border-radius: 42px;
    overflow: hidden;
    position: relative;
    background: linear-gradient(180deg, #8a9db5 0%, #3a4d68 100%);
    box-shadow: 0 18px 38px -18px rgba(20,40,60,.35);
}
.patron-info h3 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    color: var(--navy);
    margin: 0 0 28px;
    font-size: 40px;
    letter-spacing: -.01em;
}
.patron-info p {
    color: var(--muted);
    font-size: 17px;
    line-height: 1.8;
    margin: 0 0 18px;
    max-width: 500px;
}

/* ===== TESTIMONIALS ===== */
.testimonials-section { background: var(--paper); }
.testimonials {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 1100px;
    margin: 0 auto;
}
@media (max-width: 880px) { .testimonials { grid-template-columns: 1fr; } }
.testimonial {
    background: var(--bg-base);
    border-radius: 22px;
    padding: 34px 30px;
    display: flex;
    flex-direction: column;
    border: 1px solid #E5EEF5;
    transition: transform .25s, box-shadow .25s;
}
.testimonial:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 30px -14px rgba(20,40,60,.18);
}
.testimonial .qm {
    font-family: 'Playfair Display', serif;
    font-size: 60px;
    line-height: .65;
    color: var(--blue-soft);
    margin-bottom: 8px;
}
.testimonial blockquote {
    margin: 0 0 26px;
    flex: 1;
    color: var(--muted);
    font-style: italic;
    font-size: 16px;
    line-height: 1.75;
}
.testimonial .who { display: flex; align-items: center; gap: 14px; }
.testimonial .avatar {
    width: 44px; height: 44px;
    border-radius: 50%;
    background: var(--blue-soft);
    color: var(--blue);
    display: grid; place-items: center;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 18px;
}
.testimonial .name { font-weight: 700; color: var(--navy); font-size: 15px; }
.testimonial .role { font-size: 13px; color: var(--muted); }

/* ===== CONTACT ===== */
.contact { background: var(--paper); padding: 110px 0 60px; }
.contact-card {
    background: var(--bg-soft);
    border-radius: 36px;
    padding: 70px 56px 80px;
    position: relative;
    overflow: hidden;
    max-width: 1100px;
    margin: 0 auto;
}
.contact-card .lines { display: none; }
.contact-card > * { position: relative; }
.contact-card h2 {
    text-align: center;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: clamp(30px, 4.2vw, 46px);
    color: var(--navy);
    margin: 0 0 44px;
}
.form { max-width: 720px; margin: 0 auto; }
.form-field { margin-bottom: 18px; }
.form-field input,
.form-field textarea {
    width: 100%;
    background: var(--paper);
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 20px 24px;
    font-family: inherit;
    font-size: 16px;
    color: var(--text);
    box-shadow: 0 1px 2px rgba(20,40,60,.05);
    transition: border-color .2s, box-shadow .2s;
}
.form-field input:focus,
.form-field textarea:focus {
    outline: none;
    border-color: var(--blue);
    box-shadow: 0 0 0 4px rgba(63,125,179,.12);
}
.form-field input::placeholder,
.form-field textarea::placeholder { color: #9AAAB9; }
.form-field textarea { resize: vertical; min-height: 120px; }
.form-field .err {
    color: #C04848;
    font-size: 13px;
    margin-top: 6px;
    min-height: 16px;
    padding-left: 6px;
}
.submit-btn {
    background: var(--blue);
    color: #fff;
    border: 0;
    padding: 14px 30px;
    border-radius: 8px;
    font-family: inherit;
    font-weight: 700;
    font-size: 16px;
    margin-top: 8px;
    transition: background .2s, transform .15s;
}
.submit-btn:hover { background: var(--navy); transform: translateY(-1px); }
.submit-btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }

/* ===== Zgoda RODO ===== */
.form-consent { margin: 6px 0 18px; }
.consent-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}
.consent-label input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    flex: 0 0 22px;
    width: 22px; height: 22px;
    margin-top: 2px;
    border: 2px solid rgba(16,42,64,.25);
    border-radius: 5px;
    background: var(--paper);
    cursor: pointer;
    position: relative;
    transition: border-color .15s, background .15s, box-shadow .15s;
}
.consent-label input[type="checkbox"]:hover { border-color: var(--blue); }
.consent-label input[type="checkbox"]:focus-visible {
    outline: none;
    box-shadow: 0 0 0 4px rgba(63,125,179,.18);
}
.consent-label input[type="checkbox"]:checked {
    background: var(--blue);
    border-color: var(--blue);
}
.consent-label input[type="checkbox"]:checked::after {
    content: "";
    position: absolute;
    left: 6px; top: 1px;
    width: 6px; height: 12px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.consent-label.has-error input[type="checkbox"] {
    border-color: #C04848;
    box-shadow: 0 0 0 4px rgba(192,72,72,.12);
}
.consent-text {
    color: var(--muted);
    font-size: 13.5px;
    line-height: 1.6;
}
.consent-text strong { color: var(--text); font-weight: 700; }
.consent-text a {
    color: var(--blue);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
}
.consent-text a:hover { color: var(--navy); }
.form-consent .err { padding-left: 34px; }
.form-note {
    text-align: center;
    margin-top: 32px;
    color: var(--muted);
    font-size: 14.5px;
}
.form-success {
    background: #DDEFE0;
    border: 1px solid #98C3A0;
    color: #1E5A2C;
    padding: 14px 20px;
    border-radius: 12px;
    margin-top: 18px;
    font-size: 15px;
    text-align: center;
}
.form-error {
    background: #FBDCDC;
    border: 1px solid #E8A0A0;
    color: #8B2424;
    padding: 14px 20px;
    border-radius: 12px;
    margin-top: 18px;
    font-size: 15px;
    text-align: center;
}

/* ===== GALLERY — pozioma karuzela ===== */
.gallery-wrap {
    position: relative;
    margin-top: 60px;
    background: var(--paper);
    padding: 0;
}
.gallery {
    display: flex;
    flex-wrap: nowrap;            /* nigdy nie zawija */
    gap: 8px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    padding: 4px 56px;            /* miejsce na strzałki po bokach */
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;        /* Firefox */
    scrollbar-color: var(--blue-soft) transparent;
}
.gallery::-webkit-scrollbar { height: 8px; }
.gallery::-webkit-scrollbar-track { background: transparent; }
.gallery::-webkit-scrollbar-thumb {
    background: var(--blue-soft);
    border-radius: 999px;
}
.gallery::-webkit-scrollbar-thumb:hover { background: var(--blue); }

.gallery-tile {
    flex: 0 0 auto;
    width: 260px;
    height: 260px;
    border-radius: 14px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    background: transparent;
    border: 0;
    padding: 0;
    scroll-snap-align: start;
    transition: transform .3s, box-shadow .3s;
    box-shadow: 0 6px 18px -10px rgba(20,40,60,.15);
}
.gallery-tile:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 14px 30px -14px rgba(20,40,60,.25);
    z-index: 1;
}
.gallery-tile img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .4s ease;
}
.gallery-tile:hover img { transform: scale(1.05); }
/* Numeracja na małych kafelkach została usunięta. Licznik widoczny tylko w lightboxie. */

@media (max-width: 720px) {
    .gallery { padding: 4px 16px; gap: 6px; }
    .gallery-tile { width: 78vw; height: 78vw; max-width: 320px; max-height: 320px; border-radius: 12px; }
}

/* ===== Strzałki nawigacyjne karuzeli ===== */
.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    width: 44px; height: 44px;
    border-radius: 50%;
    border: 0;
    background: var(--paper);
    color: var(--navy);
    font-size: 28px;
    line-height: 1;
    box-shadow: 0 8px 22px -8px rgba(20,40,60,.3);
    display: grid;
    place-items: center;
    transition: background .2s, color .2s, transform .15s, opacity .2s;
}
.gallery-nav:hover { background: var(--blue); color: #fff; }
.gallery-nav:active { transform: translateY(-50%) scale(.94); }
.gallery-nav--prev { left: 8px; }
.gallery-nav--next { right: 8px; }
.gallery-nav[disabled] { opacity: .35; pointer-events: none; }

@media (max-width: 720px) {
    .gallery-nav { width: 38px; height: 38px; font-size: 22px; }
    .gallery-nav--prev { left: 4px; }
    .gallery-nav--next { right: 4px; }
}

/* ===== Lightbox modal ===== */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(11,35,52,.92);
    backdrop-filter: blur(6px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    transition: opacity .25s ease;
}
.lightbox.is-open {
    display: flex;
    opacity: 1;
    animation: lb-fade .25s ease;
}
@keyframes lb-fade {
    from { opacity: 0; }
    to   { opacity: 1; }
}
.lightbox__stage {
    position: relative;
    max-width: min(1100px, 92vw);
    max-height: 88vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lightbox__img {
    max-width: 100%;
    max-height: 88vh;
    border-radius: 12px;
    box-shadow: 0 24px 60px rgba(0,0,0,.55);
    object-fit: contain;
    display: block;
    background: #0B2334;
    animation: lb-pop .25s ease;
}
@keyframes lb-pop {
    from { opacity: 0; transform: scale(.96); }
    to   { opacity: 1; transform: scale(1); }
}
.lightbox__counter {
    position: absolute;
    left: 50%;
    bottom: -38px;
    transform: translateX(-50%);
    color: rgba(255,255,255,.85);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: .06em;
    background: rgba(11,35,52,.6);
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(4px);
}
.lightbox__close,
.lightbox__nav {
    position: absolute;
    border: 0;
    background: rgba(255,255,255,.1);
    color: #fff;
    border-radius: 50%;
    display: grid;
    place-items: center;
    transition: background .2s, transform .15s, color .2s;
    cursor: pointer;
}
.lightbox__close {
    top: 22px; right: 22px;
    width: 48px; height: 48px;
    font-size: 30px;
    line-height: 1;
}
.lightbox__close:hover { background: #fff; color: var(--navy); }
.lightbox__nav {
    top: 50%;
    transform: translateY(-50%);
    width: 56px; height: 56px;
    font-size: 32px;
    line-height: 1;
}
.lightbox__nav:hover { background: var(--blue); transform: translateY(-50%) scale(1.05); }
.lightbox__nav:active { transform: translateY(-50%) scale(.95); }
.lightbox__nav--prev { left: 22px; }
.lightbox__nav--next { right: 22px; }

@media (max-width: 720px) {
    .lightbox { padding: 12px; }
    .lightbox__close { top: 12px; right: 12px; width: 40px; height: 40px; font-size: 26px; }
    .lightbox__nav { width: 44px; height: 44px; font-size: 26px; }
    .lightbox__nav--prev { left: 8px; }
    .lightbox__nav--next { right: 8px; }
    .lightbox__counter { bottom: -32px; font-size: 12px; padding: 4px 10px; }
}

/* Brak scrolla na body, gdy lightbox jest otwarty */
body.lb-open { overflow: hidden; }

/* ===== Welcome modal (zapisy) ===== */
.welcome-modal {
    position: fixed;
    inset: 0;
    z-index: 2100;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    transition: opacity .3s ease;
}
.welcome-modal.is-open {
    display: flex;
    opacity: 1;
    animation: wm-fade .3s ease;
}
@keyframes wm-fade {
    from { opacity: 0; }
    to   { opacity: 1; }
}
.welcome-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(11,35,52,.78);
    backdrop-filter: blur(6px);
    cursor: pointer;
}
.welcome-modal__box {
    position: relative;
    max-width: min(640px, 92vw);
    max-height: 90vh;
    background: var(--paper);
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 30px 70px rgba(0,0,0,.45);
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: wm-pop .35s cubic-bezier(.2,.9,.3,1.2);
}
@keyframes wm-pop {
    from { opacity: 0; transform: scale(.9) translateY(20px); }
    to   { opacity: 1; transform: scale(1)  translateY(0); }
}
.welcome-modal__img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 70vh;
    object-fit: contain;
    background: var(--bg-soft);
}
.welcome-modal__close {
    position: absolute;
    top: 12px; right: 12px;
    width: 40px; height: 40px;
    border: 0;
    border-radius: 50%;
    background: rgba(11,35,52,.7);
    color: #fff;
    font-size: 26px;
    line-height: 1;
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: background .2s, transform .15s, color .2s;
    backdrop-filter: blur(4px);
    z-index: 2;
}
.welcome-modal__close:hover { background: #fff; color: var(--navy); transform: scale(1.06); }
.welcome-modal__close:active { transform: scale(.94); }
.welcome-modal__cta {
    display: inline-flex;
    align-items: center;
    margin: 18px 24px 24px;
    background: var(--blue);
    color: #fff;
    font-weight: 700;
    padding: 14px 28px;
    border-radius: 8px;
    text-decoration: none;
    transition: background .2s, transform .15s;
}
.welcome-modal__cta:hover { background: var(--navy); color: #fff; transform: translateY(-1px); }

@media (max-width: 600px) {
    .welcome-modal__box { border-radius: 16px; }
    .welcome-modal__close { width: 36px; height: 36px; font-size: 22px; top: 10px; right: 10px; }
    .welcome-modal__cta { width: calc(100% - 32px); margin: 14px 16px 18px; justify-content: center; }
}

body.wm-open { overflow: hidden; }

/* ===== FOOTER ===== */
footer {
    background: var(--footer);
    color: var(--footer-text);
    padding: 38px 0 0;
}
.footer-inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
    padding-bottom: 30px;
}
.footer-contacts {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}
.footer-contacts .item {
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--footer-text-strong);
    font-weight: 700;
    font-size: 16px;
}
.footer-contacts .item svg {
    width: 22px; height: 22px;
    color: var(--footer-text);
}
.footer-contacts a.item:hover { color: #fff; }
.footer-links {
    display: flex;
    gap: 44px;
    flex-wrap: wrap;
    align-items: center;
}
.footer-links a {
    color: var(--footer-text);
    font-size: 15px;
    transition: color .2s;
}
.footer-links a:hover { color: var(--footer-text-strong); }
.footer-copy {
    border-top: 1px solid rgba(255,255,255,.06);
    padding: 18px 0;
    font-size: 13.5px;
    color: rgba(255,255,255,.45);
    text-align: center;
}

/* ===== TO TOP ===== */
.to-top {
    position: fixed;
    bottom: 24px; right: 24px;
    width: 48px; height: 48px;
    border-radius: 50%;
    background: var(--blue);
    color: #fff;
    display: grid; place-items: center;
    box-shadow: 0 8px 22px -8px rgba(63,125,179,.7);
    font-size: 22px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity .3s, transform .3s, background .2s;
    z-index: 99;
}
.to-top.is-visible { opacity: 1; transform: translateY(0); }
.to-top:hover { background: var(--navy); color: #fff; }

/* ===== Fade-in ===== */
.fade {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity .8s ease, transform .8s ease;
}
.fade.in {
    opacity: 1;
    transform: none;
}
#stcm-modal footer {
  background-color: var(--backgroundColor) !important;
  background: transparent !important;
}
