/**
 * Coral: vzhled potvrzení na místě a listu zespodu (wp-assets/coral-potvrd.js, Světlina 883).
 *
 * Kostra a pohyb jsou z jádra, barvy z aplikace. Bez nastavení bere díl barvu
 * a písmo místa, kde stojí; aplikace ho doladí proměnnými na :root:
 *
 *   --coral-potvrd-akcent, --coral-potvrd-na-akcentu         potvrzující tlačítko a jeho text
 *   --coral-potvrd-nebezpeci, --coral-potvrd-na-nebezpeci    mazací tlačítko a jeho text
 *   --coral-potvrd-hrana, --coral-potvrd-najeti, --coral-potvrd-fokus
 *   --coral-potvrd-roh, --coral-potvrd-vyska (aspoň 40px), --coral-potvrd-pismo, --coral-potvrd-mezera
 *   --coral-list-plocha, --coral-list-text, --coral-list-zatemneni, --coral-list-stin
 *   --coral-list-roh, --coral-list-sirka, --coral-list-krok, --coral-list-uchyt, --coral-list-z
 *
 * Aplikace s vlastními tlačítky jim dá své třídy (window.coralPotvrd.tridy)
 * a pravidla .coral-potvrd-tl se jí netýkají.
 * Telefon (do 767 px): list od kraje ke kraji zespodu. Od 768 px okno uprostřed.
 */
.coral-potvrzeni { display: inline-flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: var(--coral-potvrd-mezera, 6px); max-width: 100%; font-size: var(--coral-potvrd-pismo, 0.875em); font-weight: 700; animation: coral-potvrd-prichod 160ms ease; }
.coral-potvrzeni__tlacitka { display: inline-flex; flex-wrap: nowrap; gap: var(--coral-potvrd-mezera, 6px); }
.coral-potvrzeni--dlouhe { display: flex; padding: 4px 0 6px; }
.coral-potvrzeni--dlouhe .coral-potvrzeni__text { flex: 1 1 100%; font-weight: 600; line-height: 1.45; }
.coral-potvrzeni--pole { justify-content: flex-start; }
.coral-potvrzeni--pole .coral-potvrzeni__pole { flex: 1 1 170px; width: auto; min-width: 0; max-width: 300px; }
.coral-potvrzeni--pole .coral-potvrzeni__tlacitka { margin-left: auto; }
@keyframes coral-potvrd-prichod { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: none; } }

.coral-potvrd-tl { display: inline-flex; align-items: center; justify-content: center; min-height: var(--coral-potvrd-vyska, 40px); min-width: 40px; margin: 0; padding: 0 14px; border: 1px solid var(--coral-potvrd-hrana, color-mix(in srgb, currentColor 24%, transparent)); border-radius: var(--coral-potvrd-roh, 999px); background: transparent; color: inherit; font: inherit; font-weight: 700; line-height: 1.2; white-space: nowrap; cursor: pointer; outline: none; -webkit-tap-highlight-color: transparent; transition: background-color 160ms ease, box-shadow 160ms ease, transform 160ms cubic-bezier(0.22, 1, 0.36, 1), filter 160ms ease; }
.coral-potvrd-tl:hover { background-color: var(--coral-potvrd-najeti, color-mix(in srgb, currentColor 10%, transparent)); }
.coral-potvrd-tl:focus-visible { box-shadow: 0 0 0 3px var(--coral-potvrd-fokus, color-mix(in srgb, currentColor 34%, transparent)); }
.coral-potvrd-tl:active { transform: scale(0.96); }
.coral-potvrd-tl--akcent { border-color: transparent; background-color: var(--coral-potvrd-akcent, color-mix(in srgb, currentColor 18%, transparent)); color: var(--coral-potvrd-na-akcentu, inherit); }
.coral-potvrd-tl--nebezpeci { border-color: transparent; background-color: var(--coral-potvrd-nebezpeci, #b3392f); color: var(--coral-potvrd-na-nebezpeci, #fff); }
.coral-potvrd-tl--akcent:hover, .coral-potvrd-tl--nebezpeci:hover { filter: brightness(1.08) saturate(1.08); }
.coral-potvrd-tl--akcent:hover { background-color: var(--coral-potvrd-akcent, color-mix(in srgb, currentColor 26%, transparent)); }
.coral-potvrd-tl--nebezpeci:hover { background-color: var(--coral-potvrd-nebezpeci, #b3392f); }
.coral-potvrd-pole { min-height: var(--coral-potvrd-vyska, 40px); padding: 4px 12px; border: 1px solid var(--coral-potvrd-hrana, color-mix(in srgb, currentColor 24%, transparent)); border-radius: var(--coral-potvrd-roh, 999px); background: transparent; color: inherit; font: inherit; outline: none; }
.coral-potvrd-pole:focus { box-shadow: 0 0 0 3px var(--coral-potvrd-fokus, color-mix(in srgb, currentColor 34%, transparent)); }

.coral-list { position: fixed; inset: 0; z-index: var(--coral-list-z, 100000); display: flex; align-items: flex-end; justify-content: center; padding: calc(env(safe-area-inset-top, 0px) + 28px) 0 0; background: var(--coral-list-zatemneni, rgba(10, 14, 18, 0.46)); opacity: 0; transition: opacity 240ms ease; touch-action: none; overscroll-behavior: contain; -webkit-tap-highlight-color: transparent; }
.coral-list.je-otevrene { opacity: 1; }
.coral-list__karta { position: relative; box-sizing: border-box; display: flex; flex-direction: column; gap: var(--coral-list-krok, 16px); width: 100%; max-height: 100%; overflow-y: auto; overscroll-behavior: contain; padding: calc(var(--coral-list-krok, 16px) + 14px) var(--coral-list-krok, 16px) calc(var(--coral-list-krok, 16px) + env(safe-area-inset-bottom, 0px)); border-radius: var(--coral-list-roh, 22px) var(--coral-list-roh, 22px) 0 0; background: var(--coral-list-plocha, Canvas); color: var(--coral-list-text, CanvasText); box-shadow: var(--coral-list-stin, 0 -12px 40px rgba(0, 0, 0, 0.24)); outline: none; transform: translateY(100%); transition: transform 320ms cubic-bezier(0.22, 1, 0.36, 1); }
.coral-list.je-otevrene > .coral-list__karta { transform: none; }
.coral-list.je-zavira > .coral-list__karta { transition: transform 240ms cubic-bezier(0.4, 0, 1, 1); }
/* Úchyt listu: říká, že jde stáhnout prstem. */
.coral-list__karta::before { content: ""; position: absolute; top: 10px; left: 50%; width: 38px; height: 5px; margin-left: -19px; border-radius: 3px; background: var(--coral-list-uchyt, color-mix(in srgb, currentColor 22%, transparent)); pointer-events: none; }
.coral-list__nadpis { margin: 0; font-size: 1.2em; font-weight: 700; line-height: 1.25; text-wrap: balance; }
.coral-list__text { margin: 0; line-height: 1.5; }
.coral-list__obsah { min-width: 0; }
.coral-list__akce { display: flex; flex-direction: column; gap: 8px; }
.coral-list__akce > * { width: 100%; min-height: 44px; }

@media (min-width: 768px) {
    .coral-list { align-items: center; padding: var(--coral-list-krok, 16px); touch-action: auto; }
    .coral-list__karta { width: min(100%, var(--coral-list-sirka, 440px)); padding: calc(var(--coral-list-krok, 16px) + 8px); border-radius: var(--coral-list-roh, 22px); box-shadow: var(--coral-list-stin, 0 24px 60px rgba(0, 0, 0, 0.28)); transform: translateY(14px) scale(0.97); }
    .coral-list__karta::before { display: none; }
    .coral-list__akce { flex-direction: row-reverse; justify-content: flex-start; }
    .coral-list__akce > * { width: auto; min-height: var(--coral-potvrd-vyska, 40px); }
}
@media (prefers-reduced-motion: reduce) {
    .coral-potvrzeni { animation: none; }
    .coral-list, .coral-list__karta, .coral-list.je-zavira > .coral-list__karta, .coral-potvrd-tl { transition: none; }
    .coral-list:not(.je-otevrene) > .coral-list__karta { transform: none; }
}
