/* ===== Fotomagnetky.cz — nový frontend (věrná kopie původního vzhledu) ===== */

/* Fonty hostujeme sami (rychlost + GDPR) */
@font-face {
    font-family: 'Mulish'; font-style: normal; font-weight: 300; font-display: swap;
    src: url('/assets/fonts/mulish-v18-latin_latin-ext-300.woff2') format('woff2');
}
@font-face {
    font-family: 'Mulish'; font-style: normal; font-weight: 400; font-display: swap;
    src: url('/assets/fonts/mulish-v18-latin_latin-ext-regular.woff2') format('woff2');
}
@font-face {
    font-family: 'Mulish'; font-style: normal; font-weight: 600; font-display: swap;
    src: url('/assets/fonts/mulish-v18-latin_latin-ext-600.woff2') format('woff2');
}
@font-face {
    font-family: 'Mulish'; font-style: normal; font-weight: 700; font-display: swap;
    src: url('/assets/fonts/mulish-v18-latin_latin-ext-700.woff2') format('woff2');
}
@font-face {
    font-family: 'Mulish'; font-style: normal; font-weight: 800; font-display: swap;
    src: url('/assets/fonts/mulish-v18-latin_latin-ext-800.woff2') format('woff2');
}
@font-face {
    font-family: 'Special Elite'; font-style: normal; font-weight: 400; font-display: swap;
    src: url('/assets/fonts/special-elite-v20-latin-regular.woff2') format('woff2');
}

:root {
    --blue: #1e9ff2;
    --blue-dark: #0d8ce0;
    --green: #2ecc11;
    --green-dark: #29b30f;
    --indigo: #5f74b8;
    --red: #f0555a;
    --orange: #ff8c33;
    --orange-light: #ffb95e;
    --purple: #9b6bd4;
    --pink: #ff6f9c;
    --cyan-bg: #d9f6fb;
    --gold: #b3903f;
    --text: #6b6b6b;
    --text-dark: #3f3f3f;
    --line: #d9d9d9;
    --font: 'Mulish', 'Segoe UI', sans-serif;
    --font-price: 'Special Elite', 'Courier New', monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

/* Atribut hidden musí vyhrát nad jakýmkoli display v tomto souboru */
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--font);
    font-weight: 300;
    color: var(--text);
    background: #fff;
    line-height: 1.55;
    font-size: 17px;
}

img { max-width: 100%; display: block; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

.page { max-width: 860px; margin: 0 auto; padding: 0 0 40px; }

/* ---------- Červená stužka s logem ---------- */
.brand-ribbon {
    position: fixed;
    top: 0; left: 0;
    z-index: 50;
    background: var(--red);
    color: #fff;
    width: 62px;
    padding: 26px 0 30px;
    text-align: center;
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 16px), 50% 100%, 0 calc(100% - 16px));
    box-shadow: 0 2px 6px rgba(0,0,0,.25);
}
.brand-ribbon span {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    font-weight: 800;
    font-size: 19px;
    letter-spacing: 1px;
    color: #fff;
}
.brand-ribbon:hover { text-decoration: none; }

/* ---------- Tlačítka ---------- */
.btn {
    display: inline-block;
    border: 0;
    cursor: pointer;
    font-family: var(--font);
    font-weight: 600;
    font-size: 19px;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: #fff;
    padding: 13px 26px;
    transition: background .15s, opacity .15s;
    text-align: center;
}
.btn:hover { text-decoration: none; opacity: .92; }
.btn-blue   { background: var(--blue); }
.btn-blue:hover { background: var(--blue-dark); }
.btn-green  { background: var(--green); }
.btn-green:hover { background: var(--green-dark); }
.btn-indigo { background: var(--indigo); }
.btn-dark   { background: #3a3a3a; border-radius: 8px; }
.btn-block  { display: block; width: 100%; }
.btn[disabled], .btn.is-busy { pointer-events: none; }
.btn.is-busy { background: var(--pink); }

.linklike {
    background: none; border: 0; padding: 0;
    color: var(--blue); font: inherit; cursor: pointer;
    text-transform: inherit;
}

.req { color: var(--red); }

/* ---------- Hero (úvod) ---------- */
.hero { position: relative; }
.hero-slider { position: relative; aspect-ratio: 6 / 5; overflow: hidden; background: #eee; }
.hero-slider img {
    position: absolute; inset: 0;
    width: 100%; height: 100%; object-fit: cover;
    opacity: 0; transition: opacity .6s;
}
.hero-slider img.active { opacity: 1; }
.hero-badge {
    position: absolute; top: 18px; right: 0;
    background: var(--orange);
    color: #fff;
    font-weight: 600;
    text-transform: uppercase;
    padding: 10px 18px;
    font-size: 17px;
}
.hero-arrows {
    position: absolute; right: 0; bottom: -40px;
    display: flex; flex-direction: column; gap: 8px;
}
.hero-arrows button {
    background: #000; color: #fff; border: 0;
    width: 74px; height: 60px; font-size: 18px; cursor: pointer;
}
.hero-cta {
    position: absolute; left: 50%; bottom: -26px;
    transform: translateX(-50%);
    white-space: nowrap;
    z-index: 2;
}

/* ---------- Sekce úvodky ---------- */
.section { padding: 60px 24px 30px; text-align: left; }
.section .btn { margin: 10px 0; }
.headline { font-weight: 300; line-height: 1.25; }
.headline a { color: var(--blue); font-weight: 300; }
.headline a:hover { text-decoration: none; }
h1.headline { font-size: 42px; }
h2.headline { font-size: 32px; }
.lead { margin: 18px 0; color: var(--text-dark); font-weight: 400; }

.testimonial {
    font-size: 20px; color: var(--text-dark);
    border-left: 4px solid var(--line);
    padding-left: 16px;
}
.testimonial cite { display: block; margin-top: 8px; font-style: normal; font-weight: 700; }

.contact-block p { margin-bottom: 10px; }

/* ---------- Patička ---------- */
.site-footer { padding: 40px 24px 20px; text-align: center; }
.footer-nav { color: #c9c9c9; font-size: 18px; letter-spacing: .5px; }
.footer-nav a { color: #b5b5b5; margin: 0 4px; }
.footer-nav span { margin: 0 2px; }
.copyright { margin-top: 34px; color: #b5b5b5; font-size: 15px; }

.user-box { text-align: center; padding: 30px 0 0; }
.user-welcome { color: #9a9a9a; font-size: 20px; letter-spacing: 1px; }
.user-logout { color: #b5b5b5; letter-spacing: 2px; }

/* ---------- Přihlášení ---------- */
.login-page { padding: 30px 24px 60px; }
.strip-banner {
    background: #f1f1f1;
    color: var(--blue);
    font-weight: 800;
    text-transform: uppercase;
    text-align: center;
    font-size: 21px;
    padding: 8px 12px;
    margin-bottom: 26px;
}
.login-heading {
    font-size: 24px; font-weight: 700; color: var(--text-dark);
    text-align: center; margin-bottom: 24px;
}
.login-consent { text-align: center; margin-bottom: 28px; }
.login-consent a { color: var(--text-dark); font-weight: 700; }
.login-form label {
    display: block;
    text-transform: uppercase;
    font-weight: 400; font-size: 15px;
    letter-spacing: .5px;
    color: var(--text-dark);
    margin-bottom: 8px;
}
.login-form input[type=email] {
    display: block; width: 100%;
    border: 2px solid #1a1a1a;
    padding: 14px 12px;
    font-size: 18px; font-family: var(--font);
    margin-bottom: 22px;
}
.form-error { color: var(--red); font-weight: 600; margin: 8px 0; font-size: 15px; }

/* ---------- Objednávková stránka ---------- */
.order-page { padding: 26px 24px 10px; }
.order-heading {
    font-weight: 300; font-size: 34px; line-height: 1.3;
    text-align: center; margin-bottom: 26px;
}
.order-info { text-align: center; margin: 22px 0; }
.order-info strong { font-weight: 700; color: var(--text-dark); }

.banner {
    padding: 14px 18px;
    color: #fff; font-weight: 400; font-size: 19px;
    margin: 16px 0;
}
.banner-orange { background: var(--orange-light); color: #7a4a00; text-align: center; font-weight: 600; }
.banner-purple { background: var(--purple); }
.banner-cyan   { background: var(--cyan-bg); color: var(--text-dark); }

/* Košík */
.cart-head {
    display: flex; justify-content: space-between;
    text-transform: uppercase; letter-spacing: 1px;
    color: var(--text-dark); font-weight: 400; font-size: 17px;
    margin: 26px 0 10px;
}
.cart-list { list-style: none; }
.cart-item {
    display: grid;
    grid-template-columns: minmax(90px, 240px) 1fr auto auto;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-top: 1px solid #eee;
}
.cart-thumb {
    background:
        repeating-linear-gradient(90deg, #ccc 0 22px, transparent 22px 34px) top / 100% 8px no-repeat,
        repeating-linear-gradient(90deg, #ccc 0 22px, transparent 22px 34px) bottom / 100% 8px no-repeat,
        repeating-linear-gradient(0deg, #ccc 0 22px, transparent 22px 34px) left / 8px 100% no-repeat,
        repeating-linear-gradient(0deg, #ccc 0 22px, transparent 22px 34px) right / 8px 100% no-repeat;
    padding: 10px;
    border: 0; cursor: pointer;
}
.cart-name { color: var(--text-dark); font-size: 19px; }
.qty-stepper { display: flex; flex-direction: column; width: 72px; }
.qty-stepper button {
    background: #e3e3e3; border: 0; cursor: pointer;
    font-size: 18px; font-weight: 700; padding: 4px 0;
}
.qty-stepper button:active { background: var(--blue); color: #fff; }
.qty-input {
    width: 100%; text-align: center;
    border: 1px solid #1a1a1a;
    font-size: 20px; padding: 8px 0;
    font-family: var(--font);
}
.cart-remove {
    background: none; border: 0; color: #9a9a9a;
    font-size: 30px; cursor: pointer; padding: 4px 8px;
}
.cart-remove:hover { color: var(--red); }

.cart-total {
    display: flex; justify-content: space-between; align-items: center;
    border-top: 4px solid #eee; border-bottom: 4px solid #eee;
    padding: 18px 0; margin: 18px 0;
}
.cart-total-label {
    text-transform: uppercase; font-weight: 700;
    color: var(--text-dark); font-size: 17px; max-width: 150px;
    line-height: 1.3;
}
.price-display { font-family: var(--font-price); font-size: 34px; color: var(--text); }

.cart-empty { text-align: center; margin: 30px 0; }

/* Panel nahrávání */
.upload-panel {
    position: fixed; inset: 0 12% 0 0;
    background: #fff;
    z-index: 100;
    padding: 24px 20px;
    overflow-y: auto;
    box-shadow: 4px 0 18px rgba(0,0,0,.45);
}
.upload-backdrop {
    position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 99;
}
.upload-close-ribbon {
    display: block;
    background: var(--indigo); color: #fff;
    border: 0; cursor: pointer;
    text-transform: uppercase; letter-spacing: 2px;
    font-size: 16px; font-weight: 400;
    padding: 16px 34px 16px 18px;
    margin: 10px 0 30px -20px;
    clip-path: polygon(0 0, calc(100% - 22px) 0, 100% 50%, calc(100% - 22px) 100%, 0 100%);
}
.dropzone {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 14px;
    margin: 0 auto;
    max-width: 420px;
    aspect-ratio: 10 / 7.4;
    cursor: pointer;
    background:
        repeating-linear-gradient(90deg, #c9c9c9 0 44px, transparent 44px 68px) top / 100% 10px no-repeat,
        repeating-linear-gradient(90deg, #c9c9c9 0 44px, transparent 44px 68px) bottom / 100% 10px no-repeat,
        repeating-linear-gradient(0deg, #c9c9c9 0 44px, transparent 44px 68px) left / 10px 100% no-repeat,
        repeating-linear-gradient(0deg, #c9c9c9 0 44px, transparent 44px 68px) right / 10px 100% no-repeat;
}
.dropzone.dragover { background-color: #eef7ff; }
.dz-cloud { width: 110px; }
.dz-label {
    text-transform: uppercase; letter-spacing: 3px;
    color: var(--text-dark); font-weight: 600; font-size: 21px;
}
.upload-hint {
    text-align: center; text-transform: uppercase;
    letter-spacing: 2px; font-size: 15px;
    margin: 26px auto; max-width: 420px;
}
.upload-progress { list-style: none; max-width: 420px; margin: 0 auto; }
.upload-progress li {
    display: flex; flex-direction: column; gap: 8px;
    background: var(--blue);
    color: #fff;
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 12px;
    font-size: 14px;
}
.upload-progress li.done { background: var(--green-dark); }
.upload-progress li.error { background: var(--red); }
.upload-progress .fname {
    font-weight: 600;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.upload-progress .bar {
    height: 14px; border-radius: 8px; background: #fff; overflow: hidden;
}
.upload-progress .bar i {
    display: block; height: 100%; width: 0;
    background: var(--orange-light);
    transition: width .2s;
}
.upload-progress li.processing .bar i { animation: upload-pulse 1s ease-in-out infinite alternate; }
@keyframes upload-pulse { from { opacity: 1; } to { opacity: .35; } }

/* Modal ořezu */
.crop-modal {
    position: fixed; inset: 0; z-index: 200;
    background: rgba(20,20,20,.94);
    display: flex; align-items: center; justify-content: center;
    padding: 16px;
}
.crop-dialog { width: 100%; max-width: 640px; }
.crop-dialog h2 {
    color: #555; font-weight: 700; font-size: 22px; margin-bottom: 14px;
}
.crop-stage { max-height: 62vh; }
.crop-stage img { max-width: 100%; }
.crop-controls { margin-top: 26px; text-align: center; }
.crop-rotate {
    background: #2c2c2c; color: #ddd; border: 0; cursor: pointer;
    width: 52px; height: 52px; border-radius: 12px; font-size: 22px;
    box-shadow: 0 2px 6px rgba(0,0,0,.6);
}
.crop-buttons { display: flex; justify-content: center; gap: 18px; margin-top: 22px; }
.crop-buttons .btn { min-width: 130px; text-transform: none; font-size: 18px; font-weight: 400; }

/* ---------- Pokladna ---------- */
.checkout-page { padding: 30px 24px; }
.coupon-toggle {
    text-align: center; font-size: 21px;
    color: var(--text-dark); font-weight: 400;
}
.coupon-toggle .linklike { text-transform: uppercase; }
.coupon-row { margin: 14px 0; text-align: center; }
.coupon-row label { display: block; margin-bottom: 6px; }
.coupon-row input {
    border: 2px solid #1a1a1a; padding: 10px; font-size: 17px;
    font-family: var(--font); width: 240px; max-width: 100%;
}
.thin-divider { border: 0; border-top: 2px solid #ddd; margin: 18px 0; }
.terms-note { text-align: center; color: var(--gold); font-size: 19px; margin-bottom: 26px; }
.terms-note a { color: var(--gold); text-decoration: underline; }

.section-heading {
    font-weight: 300; font-size: 34px; color: #8a8a8a;
    display: flex; align-items: center; gap: 16px;
    margin: 26px 0 30px;
}
.section-heading::after { content: ''; flex: 1; height: 4px; background: #e3e3e3; }

.form-grid label {
    display: block; margin-bottom: 20px;
    color: var(--text-dark); font-size: 19px;
}
.form-grid input {
    display: block; width: 100%;
    border: 2px solid #1a1a1a;
    padding: 15px 12px;
    font-size: 18px; font-family: var(--font);
    margin-top: 8px;
}
.form-grid input::placeholder { color: #b5b5b5; }
.form-grid .form-error { display: block; }

/* Souhrn objednávky */
.order-summary { border: 3px solid var(--blue); padding: 20px 16px; margin-top: 26px; }
.summary-head {
    display: flex; justify-content: space-between;
    text-transform: uppercase; font-weight: 700; color: var(--text-dark);
    font-size: 16px; letter-spacing: .5px; margin-bottom: 14px;
}
.summary-head span:last-child { text-align: right; max-width: 90px; }
.summary-row {
    display: flex; justify-content: space-between;
    padding: 4px 0; font-size: 18px;
}
.summary-row b { font-weight: 800; }
.summary-subtotal { font-weight: 700; color: var(--text-dark); text-transform: uppercase; }

.shipping-options { margin: 20px 0; }
.radio-row {
    display: flex; align-items: center; gap: 12px;
    padding: 8px 0; font-size: 17px; letter-spacing: .5px;
    cursor: pointer;
}
.radio-row input, .pay-row input { width: 22px; height: 22px; accent-color: var(--blue); flex-shrink: 0; }

.summary-total {
    display: flex; justify-content: space-between; align-items: center;
    border-top: 3px solid #e3e3e3; border-bottom: 3px solid #e3e3e3;
    padding: 14px 0; margin: 14px 0 22px;
}
.summary-total > span:first-child {
    text-transform: uppercase; color: var(--blue); font-weight: 800; font-size: 19px;
}

.payment-options { margin-bottom: 22px; }
.pay-row {
    display: flex; gap: 12px; align-items: flex-start;
    padding: 14px; margin-bottom: 10px; cursor: pointer;
    font-size: 17px;
}
.pay-row .pay-title { display: block; text-transform: uppercase; letter-spacing: .5px; }
.pay-row .pay-desc { display: block; margin-top: 8px; }
.pay-prevod { background: var(--cyan-bg); color: var(--text-dark); }
.pay-prevod .pay-desc { color: var(--text); }
.pay-twisto { background: var(--orange-light); color: #4a3000; }
.pay-karta  { background: #fff; }
.pay-row:has(input:not(:checked)) .pay-desc { display: none; }
.btn-order { min-width: 200px; }

/* ---------- Děkujeme ---------- */
.thankyou-page { padding: 30px 24px; }
.thankyou-page p { margin-bottom: 20px; }
.ty-intro { color: #9a9a9a; font-size: 19px; }
.ty-payment { font-size: 30px; font-weight: 300; line-height: 1.4; color: var(--text-dark); }
.ty-payment strong { font-weight: 700; }
.ty-heading { font-weight: 300; font-size: 52px; line-height: 1.15; margin-bottom: 18px; }
.ty-subheading { font-weight: 300; font-size: 38px; margin-bottom: 14px; }
.bank-list, .order-recap { list-style: disc; margin: 0 0 24px 24px; }
.bank-list li, .order-recap li { margin-bottom: 6px; }
.bank-list strong, .order-recap strong { color: var(--text-dark); }
.qr-label { color: #9a9a9a; font-size: 21px; }
.qr-code { margin: 10px 0 26px; }
.qr-code img, .qr-code canvas { width: 210px; height: 210px; image-rendering: pixelated; }

/* ---------- Statické stránky ---------- */
.static-page { padding: 36px 24px; }
.static-page h1 { font-weight: 300; font-size: 38px; margin-bottom: 24px; }
.static-page h2 { font-weight: 700; font-size: 24px; color: var(--text-dark); margin: 28px 0 12px; }
.static-page p, .static-page li { margin-bottom: 12px; }
.price-list { margin: 0 0 24px 22px; }
.contact-form label, .track-form label { display: block; margin-bottom: 16px; color: var(--text-dark); }
.contact-form input, .contact-form textarea, .track-form input {
    display: block; width: 100%;
    border: 2px solid #1a1a1a; padding: 12px;
    font-size: 17px; font-family: var(--font);
    margin-top: 6px;
}
.contact-form .btn, .track-form .btn { margin-top: 8px; }

/* ---------- Desktop ---------- */
@media (min-width: 700px) {
    body { font-size: 18px; }
    .home .page { padding-left: 80px; }
    .hero-slider { aspect-ratio: 16 / 8; }
    .hero-cta { left: 24px; transform: none; bottom: 40px; }
    .hero-arrows { bottom: 0; }
    .section { padding: 56px 40px 26px; }
    .form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; }
    .form-grid label:nth-child(3), .form-grid label:nth-child(4) { grid-column: 1 / -1; }
    .upload-panel { inset: 0 auto 0 0; width: 560px; }
    .cart-item { grid-template-columns: 240px 1fr auto auto; }
}

/* Výběr rozměru v košíku (weby s více produkty) */
.cart-size {
    display: block;
    margin-top: 8px;
    max-width: 100%;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fff;
    font: inherit; font-size: 15px;
    color: var(--text-dark);
}
.cart-item.is-updating .cart-thumb img { opacity: .4; }

/* Lišta náhledu webů (jen na testovacím serveru) */
.site-preview {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 300;
    padding: 6px 10px;
    background: rgba(20, 20, 20, .88);
    color: #fff; font: 13px/1.4 Arial, sans-serif; text-align: center;
}
.site-preview a { color: #9fd3ff; margin: 0 6px; }
.site-preview a[aria-current] { color: #fff; font-weight: bold; text-decoration: none; }
.site-preview-spacer { height: 40px; }

/* Výběr výdejního místa (Balíkovna) */
.pickup-box { margin: 0 0 22px; padding: 14px 16px; border: 2px dashed var(--line); }
.pickup-selected { margin-bottom: 12px; color: var(--text-dark); }
.pickup-modal { position: fixed; inset: 0; z-index: 400; background: rgba(0,0,0,.6); display: flex; align-items: center; justify-content: center; }
.pickup-dialog { display: flex; flex-direction: column; width: 96vw; max-width: 1100px; height: 92vh; background: #fff; }
.pickup-dialog-head { display: flex; justify-content: space-between; align-items: center; padding: 8px 14px; border-bottom: 1px solid var(--line); color: var(--text-dark); }
.pickup-close { background: none; border: 0; font-size: 34px; line-height: 1; cursor: pointer; color: var(--text-dark); padding: 0 6px; }
.pickup-dialog iframe { flex: 1; width: 100%; border: 0; }
.ty-retry { margin: 0 0 24px; }
.ty-retry p { margin-bottom: 12px; }
