/* ============================================================
   LUMI CONTROL — KARBANTARTÁS / KÖLTÖZÉS SABLON
   ============================================================ */

:root {
    --bg: #070b14;
    --text-main: #e2e8f0;
    --text-muted: #8fa3c2;
    --gold: #f5c56b;
    --gold-glow: rgba(245, 197, 107, 0.4);
    --sky: #5eb8ff;
    --sky-glow: rgba(94, 184, 255, 0.4);
    --green: #4ade80;
    --green-glow: rgba(74, 222, 128, 0.4);
    --font-title: 'Playfair Display', serif;
    --font-hand: 'Caveat', cursive;
    --font-main: 'Inter', sans-serif;
}

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

body {
    font-family: var(--font-main);
    background-color: var(--bg);
    color: var(--text-main);
    min-height: 100vh;
    
    /* Lumi: A flexbox beállítások, amik középre teszik a kártyát tableten is */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    
    padding: 20px;
    overflow-x: hidden;
    overflow-y: auto;
    position: relative;
    -webkit-font-smoothing: antialiased;
}

/* ============================================================
   ANIMÁLT HÁTTÉR (Aurora + Csillagok)
   ============================================================ */

.tpl-bg-aurora {
    position: fixed;
    top: -50%; left: -50%; right: -50%; bottom: -50%;
    z-index: 0;
    background: 
        radial-gradient(circle at 30% 40%, rgba(94, 184, 255, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 70% 60%, rgba(245, 197, 107, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 50% 20%, rgba(167, 139, 250, 0.1) 0%, transparent 40%);
    animation: auroraMove 30s linear infinite alternate;
    pointer-events: none;
    filter: blur(60px);
}

@keyframes auroraMove {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(5%, 5%) scale(1.1); }
    100% { transform: translate(-5%, -5%) scale(0.9); }
}

.tpl-bg-stars {
    position: fixed;
    inset: 0;
    z-index: 1;
    background-image: 
        radial-gradient(1px 1px at 10% 20%, rgba(255,255,255,0.6), transparent),
        radial-gradient(1.5px 1.5px at 30% 60%, rgba(245,197,107,0.5), transparent),
        radial-gradient(1px 1px at 70% 30%, rgba(255,255,255,0.6), transparent),
        radial-gradient(1px 1px at 90% 80%, rgba(94,184,255,0.5), transparent),
        radial-gradient(1.5px 1.5px at 50% 50%, rgba(255,255,255,0.4), transparent);
    background-size: 400px 400px;
    opacity: 0.6;
    animation: starTwinkle 4s ease-in-out infinite alternate;
    pointer-events: none;
}

@keyframes starTwinkle {
    0% { opacity: 0.3; transform: scale(0.98); }
    100% { opacity: 0.7; transform: scale(1.02); }
}

/* Lumi: Lebegő szikrák */
.tpl-spark {
    position: fixed;
    width: 3px;
    height: 3px;
    background: var(--gold);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--gold);
    opacity: 0;
    z-index: 2;
    animation: sparkFloat 4s linear infinite;
    pointer-events: none;
}

@keyframes sparkFloat {
    0% { transform: translateY(0) scale(1); opacity: 0; }
    20% { opacity: 0.8; }
    80% { opacity: 0.8; }
    100% { transform: translateY(-100px) scale(0.3); opacity: 0; }
}

/* ============================================================
   A KÁRTYA
   ============================================================ */

.tpl-card {
    position: relative;
    z-index: 10;
    background: rgba(17, 26, 46, 0.65);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 40px 30px;
    
    /* Lumi: Szigorú méretkorlátok, hogy ne csússzon el */
    width: 100%;
    max-width: 460px; 
    margin: 0 auto;
    
    text-align: center;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4), 0 0 100px rgba(94, 184, 255, 0.1);
    animation: cardIn 1s cubic-bezier(.2,.9,.3,1) both;
    overflow: hidden;
}

/* Lumi: Fénycsík a kártya tetején */
.tpl-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    opacity: 0.8;
}

@keyframes cardIn {
    from { opacity: 0; transform: translateY(40px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ============================================================
   TARTALOM
   ============================================================ */

.tpl-icon {
    font-size: 56px;
    margin-bottom: 24px;
    display: inline-block;
    animation: floatIcon 4s ease-in-out infinite;
    color: var(--gold);
    line-height: 1;
}

/* Lumi: A saját sablon-ikonjaink. 💙 */
.tpl-icon .lumi-icon {
    width: 72px;
    height: 72px;
    display: block;
    filter: drop-shadow(0 0 18px rgba(245,197,107,0.35));
}

@keyframes floatIcon {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-12px) rotate(5deg); }
}

.tpl-title {
    font-family: var(--font-title);
    font-size: 32px; /* Fix méret, hogy ne nyomja szét */
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-main);
    line-height: 1.2;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.tpl-sub {
    font-family: var(--font-hand);
    font-size: 22px; /* Fix méret */
    color: var(--gold);
    margin-bottom: 20px;
    line-height: 1.2;
}

.tpl-message {
    font-size: 14px; /* Fix méret */
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 30px;
    max-width: 100%;
}

/* ============================================================
   ALSÓ SÁV (Iskola + Dátum)
   ============================================================ */

.tpl-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 14px;
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}

.tpl-school {
    font-family: var(--font-title);
    font-size: 13px;
    font-weight: 600;
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
    padding: 5px 16px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.tpl-status-bar {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-weight: 600;
}

.tpl-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
}

.tpl-status-dot.is-gold { background: var(--gold); box-shadow: 0 0 10px var(--gold-glow); }
.tpl-status-dot.is-sky { background: var(--sky); box-shadow: 0 0 10px var(--sky-glow); }
.tpl-status-dot.is-green { background: var(--green); box-shadow: 0 0 10px var(--green-glow); }

.tpl-credit {
    font-family: var(--font-main);
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
    margin-top: 2px;
}

.tpl-home-btn {
    display: inline-block;
    margin-bottom: 25px;
    padding: 12px 28px;
    background: rgba(94, 184, 255, 0.12);
    border: 1px solid rgba(94, 184, 255, 0.35);
    border-radius: 40px;
    color: var(--sky);
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all .3s ease;
    box-shadow: 0 0 20px rgba(94, 184, 255, 0.08);
}

.tpl-home-btn:hover {
    background: rgba(94, 184, 255, 0.22);
    border-color: var(--sky);
    box-shadow: 0 0 28px var(--sky-glow);
    transform: translateY(-2px);
}

/* ============================================================
   HAZAVEZETŐ GOMB (404) — Lumi: az elveszett látogató nem marad egyedül. 💙
   ============================================================ */

/* ============================================================
   HAMAROSAN (soon)
   Lumi: valami készül. És ragyogni fog. 💙
   ============================================================ */

.tpl-soon-glow {
    position: fixed;
    left: 50%;
    top: 40%;
    width: 60vmin;
    height: 60vmin;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(245, 197, 107, 0.16) 0%, rgba(94, 184, 255, 0.10) 40%, transparent 70%);
    filter: blur(20px);
    pointer-events: none;
    z-index: 1;
    animation: soonBreathe 6s ease-in-out infinite;
}

@keyframes soonBreathe {
    0%, 100% { opacity: .7; transform: translate(-50%, -50%) scale(1); }
    50%      { opacity: 1;  transform: translate(-50%, -50%) scale(1.12); }
}

.tpl-icon-soon {
    animation: soonTwinkle 4s ease-in-out infinite;
}

@keyframes soonTwinkle {
    0%, 100% { transform: scale(1) rotate(-3deg); filter: drop-shadow(0 0 10px rgba(245,197,107,.5)); }
    50%      { transform: scale(1.12) rotate(3deg); filter: drop-shadow(0 0 24px rgba(245,197,107,.9)); }
}

.tpl-soon-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
}

.tpl-soon-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--sky);
    box-shadow: 0 0 12px var(--sky-glow);
    animation: soonDot 1.4s ease-in-out infinite;
}

.tpl-soon-dots span:nth-child(2) { animation-delay: .2s; background: var(--gold); box-shadow: 0 0 12px var(--gold-glow); }
.tpl-soon-dots span:nth-child(3) { animation-delay: .4s; }

@keyframes soonDot {
    0%, 100% { opacity: .3; transform: translateY(0); }
    50%      { opacity: 1;  transform: translateY(-6px); }
}

/* ============================================================
   ÁTMENETILEG SZÜNETEL (pause)
   Lumi: néha meg kell állni. Nem hiba — szünet. 💙
   ============================================================ */

.tpl-bg-soft {
    opacity: .75;
    filter: saturate(.85);
}

.tpl-pause-glow {
    position: fixed;
    left: 50%;
    top: 45%;
    width: 70vmin;
    height: 70vmin;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(94, 184, 255, 0.13) 0%, rgba(245, 197, 107, 0.07) 45%, transparent 72%);
    filter: blur(30px);
    pointer-events: none;
    z-index: 1;
    animation: pauseBreathe 9s ease-in-out infinite;
}

@keyframes pauseBreathe {
    0%, 100% { opacity: .55; transform: translate(-50%, -50%) scale(1); }
    50%      { opacity: .9;  transform: translate(-50%, -50%) scale(1.08); }
}

.tpl-pause-resume {
    display: inline-flex;
    flex-direction: column;
    gap: 4px;
    padding: 14px 30px;
    margin-bottom: 25px;
    border-radius: 18px;
    background: rgba(94, 184, 255, 0.07);
    border: 1px solid rgba(94, 184, 255, 0.22);
}

.tpl-pause-label {
    font-family: var(--font-main);
    font-size: 10px;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.tpl-pause-date {
    font-family: var(--font-hand);
    font-size: 26px;
    color: var(--gold);
    line-height: 1.1;
    text-shadow: 0 0 20px var(--gold-glow);
}

/* ============================================================
   ESEMÉNY (event) — visszaszámláló
   Lumi: a várakozás is lehet szép. Számoljuk együtt. 💙
   ============================================================ */

.tpl-event-glow {
    position: fixed;
    left: 50%;
    top: 42%;
    width: 65vmin;
    height: 65vmin;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(245, 197, 107, 0.14) 0%, rgba(94, 184, 255, 0.09) 45%, transparent 72%);
    filter: blur(26px);
    pointer-events: none;
    z-index: 1;
    animation: soonBreathe 7s ease-in-out infinite;
}

.tpl-countdown {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.tpl-cd-unit {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    min-width: 64px;
    padding: 12px 10px;
    border-radius: 16px;
    background: rgba(94, 184, 255, 0.07);
    border: 1px solid rgba(94, 184, 255, 0.18);
}

.tpl-cd-num {
    font-family: var(--font-title);
    font-size: 28px;
    font-weight: 700;
    color: var(--gold);
    line-height: 1;
    text-shadow: 0 0 18px var(--gold-glow);
    font-variant-numeric: tabular-nums;
}

.tpl-cd-lbl {
    font-family: var(--font-main);
    font-size: 9px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.tpl-event-date {
    font-family: var(--font-hand);
    font-size: 24px;
    color: var(--sky);
    margin-bottom: 25px;
    text-shadow: 0 0 18px var(--sky-glow);
}

/* ============================================================
   MOBIL
   ============================================================ */

@media (max-width: 600px) {
    .tpl-card {
        padding: 30px 20px;
        width: 95%;
        border-radius: 20px;
    }
    .tpl-icon { font-size: 48px; }
    .tpl-message { font-size: 13px; }
}