/* =========================================================
   KakasTech DISCOVER.CSS
   Top / Friss oldalak – egységes, világos prémium megjelenés
   Betöltés: global.css -> header-footer.css -> discover.css
   ========================================================= */

.discover-main {
    width: min(100% - 32px, 1440px);
    max-width: 1440px;
    margin: 24px auto 72px;
}

/* =========================================================
   Vékony prémium hero
   ========================================================= */
.discover-hero {
    position: relative;
    isolation: isolate;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 22px;
    min-height: 112px;
    padding: 17px 20px 17px 22px;
    overflow: hidden;
    border: 1px solid rgba(0, 84, 168, .18);
    border-top: 3px solid #ffc400;
    border-radius: 5px;
    background:
        radial-gradient(circle at 86% 12%, rgba(93, 173, 226, .14), transparent 27%),
        radial-gradient(circle at 9% 100%, rgba(255, 196, 0, .13), transparent 30%),
        linear-gradient(105deg, rgba(255, 255, 255, .98) 0%, rgba(247, 252, 255, .98) 58%, rgba(236, 247, 255, .98) 100%);
    box-shadow:
        0 12px 28px rgba(0, 84, 168, .09),
        inset 0 1px 0 rgba(255, 255, 255, .95);
}

.discover-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: linear-gradient(112deg, transparent 0 37%, rgba(255, 255, 255, .58) 46%, transparent 56% 100%);
    transform: translateX(-120%);
    animation: ktDiscoverHeroShine 9s ease-in-out infinite;
}

.discover-hero::after {
    content: "";
    position: absolute;
    right: 92px;
    top: 17px;
    bottom: 17px;
    width: 1px;
    background: linear-gradient(180deg, transparent, rgba(0, 84, 168, .16), transparent);
}

.discover-hero-copy {
    min-width: 0;
}

.discover-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    margin: 0 0 7px;
    padding: 4px 9px;
    border: 1px solid rgba(0, 84, 168, .19);
    border-radius: 4px;
    background: rgba(255, 255, 255, .84);
    color: #0054a8;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .88);
    font-size: .66rem;
    font-weight: 950;
    letter-spacing: .09em;
    line-height: 1;
    text-transform: uppercase;
}

.discover-main--top .discover-kicker {
    border-color: rgba(255, 174, 0, .34);
    color: #8a6100;
    background: linear-gradient(180deg, #fffdf4, #fff7d8);
}

.discover-hero-title-row {
    display: flex;
    align-items: baseline;
    gap: 18px;
    min-width: 0;
}

.discover-hero h1 {
    flex: 0 0 auto;
    margin: 0;
    color: #07192d;
    font-size: clamp(1.82rem, 3vw, 2.42rem);
    font-weight: 900;
    letter-spacing: -.035em;
    line-height: .98;
}

.discover-hero p:not(.discover-kicker) {
    min-width: 0;
    max-width: 760px;
    margin: 0;
    color: #526f89;
    font-size: .87rem;
    font-weight: 720;
    line-height: 1.42;
}

.discover-hero-icon {
    position: relative;
    display: grid;
    place-items: center;
    width: 68px;
    height: 68px;
    margin-right: 2px;
    overflow: visible;
    border: 1px solid rgba(0, 84, 168, .18);
    border-radius: 5px;
    background:
        radial-gradient(circle at 32% 24%, rgba(255, 255, 255, .96), transparent 32%),
        linear-gradient(145deg, #ffffff, #eaf5ff);
    box-shadow:
        0 10px 24px rgba(0, 84, 168, .12),
        inset 0 1px 0 rgba(255, 255, 255, .96),
        inset 0 -3px 0 rgba(0, 84, 168, .08);
}

.discover-hero-icon::after {
    content: "";
    position: absolute;
    inset: -7px;
    z-index: -1;
    border: 1px solid rgba(93, 173, 226, .10);
    border-radius: 5px;
    opacity: .7;
    animation: ktDiscoverIconHalo 5.8s ease-in-out infinite;
}

/* =========================================================
   TOP – prémium tűz ikon a kért narancs lánggal
   ========================================================= */
.discover-main--top .discover-hero-icon {
    border-color: rgba(255, 196, 0, .28);
    background:
        radial-gradient(circle at 34% 24%, rgba(255, 255, 255, .96), transparent 34%),
        linear-gradient(145deg, #ffffff, #fff9e8);
    box-shadow:
        0 10px 24px rgba(0, 84, 168, .10),
        0 0 0 1px rgba(255, 196, 0, .08),
        inset 0 1px 0 rgba(255, 255, 255, .98),
        inset 0 -3px 0 rgba(255, 196, 0, .10);
}

.discover-main--top .discover-hero-icon::after {
    border-color: rgba(255, 196, 0, .18);
}

.discover-fire-emoji {
    display: inline-grid;
    place-items: center;
    width: 1em;
    height: 1em;
    font-size: 30px;
    line-height: 1;
    transform-origin: 50% 88%;
    filter: drop-shadow(0 6px 10px rgba(0, 84, 168, .12)) drop-shadow(0 0 8px rgba(255, 196, 0, .16));
    animation: ktDiscoverFireEmoji 4.8s ease-in-out infinite;
}

/* =========================================================
   FRISS – CSS villám, ritka elektromos impulzussal
   ========================================================= */
.discover-bolt {
    position: relative;
    display: grid;
    place-items: center;
    width: 46px;
    height: 48px;
}

.discover-bolt-shape {
    position: relative;
    z-index: 2;
    display: block;
    width: 28px;
    height: 40px;
    background: linear-gradient(145deg, #ffe972 0%, #ffc400 48%, #ff9d00 100%);
    clip-path: polygon(49% 0, 100% 0, 69% 39%, 95% 39%, 25% 100%, 43% 55%, 12% 55%);
    filter:
        drop-shadow(0 0 3px rgba(255,255,255,.8))
        drop-shadow(0 8px 10px rgba(0,84,168,.22));
    animation: ktDiscoverBoltPulse 4.8s ease-in-out infinite;
}

.discover-bolt-ring {
    position: absolute;
    inset: 2px;
    z-index: 1;
    display: block;
    border: 1px solid rgba(0, 84, 168, .22);
    border-radius: 50%;
    box-shadow: inset 0 0 14px rgba(93,173,226,.12);
    animation: ktDiscoverBoltRing 4.8s ease-out infinite;
}

.discover-bolt-dot {
    position: absolute;
    z-index: 3;
    display: block;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #1ad7ef;
    box-shadow: 0 0 9px rgba(26,215,239,.78);
    opacity: 0;
}

.discover-bolt-dot--one {
    left: 2px;
    top: 13px;
    animation: ktDiscoverBoltDot 4.8s .5s ease-out infinite;
}

.discover-bolt-dot--two {
    right: 1px;
    bottom: 10px;
    animation: ktDiscoverBoltDot 4.8s 1.2s ease-out infinite;
}

/* =========================================================
   Kártyarács
   ========================================================= */
.discover-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.discover-card {
    position: relative;
    isolation: isolate;
    display: grid;
    grid-template-rows: auto minmax(96px, auto);
    min-width: 0;
    overflow: hidden;
    border: 1px solid rgba(0, 84, 168, .16);
    border-radius: 5px;
    background: rgba(255,255,255,.96);
    color: #07192d;
    box-shadow:
        0 10px 24px rgba(0, 84, 168, .08),
        inset 0 1px 0 rgba(255,255,255,.94);
    text-decoration: none;
    transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
}

.discover-card::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 5;
    pointer-events: none;
    background: linear-gradient(112deg, transparent 0 36%, rgba(255,255,255,.54) 47%, transparent 58% 100%);
    transform: translateX(-125%);
    opacity: 0;
}

.discover-card:hover {
    transform: translateY(-4px);
    border-color: rgba(0, 84, 168, .31);
    box-shadow:
        0 18px 36px rgba(0, 84, 168, .13),
        0 0 0 1px rgba(255,196,0,.08),
        inset 0 1px 0 rgba(255,255,255,.96);
}

.discover-card:hover::after {
    opacity: 1;
    animation: ktDiscoverCardShine .72s ease-out 1;
}

.discover-card-image {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background:
        radial-gradient(circle at 20% 15%, rgba(93,173,226,.22), transparent 38%),
        linear-gradient(135deg, #eef8ff, #dceeff);
}

.discover-card-image::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 56%, rgba(7,25,45,.18));
    pointer-events: none;
}

.discover-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .45s cubic-bezier(.22,1,.36,1), filter .45s ease;
}

.discover-card:hover .discover-card-image img {
    transform: scale(1.045);
    filter: saturate(1.04) contrast(1.025);
}

.discover-card-body {
    display: grid;
    align-content: space-between;
    gap: 14px;
    min-width: 0;
    padding: 15px 16px 14px;
    border-top: 3px solid rgba(0,84,168,.10);
    background:
        radial-gradient(circle at 100% 0%, rgba(93,173,226,.09), transparent 34%),
        linear-gradient(180deg, #fff 0%, #f8fbff 100%);
}

.discover-card-title {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    color: #07192d;
    font-size: 1rem;
    font-weight: 850;
    line-height: 1.28;
}

.discover-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: #688299;
    font-size: .73rem;
    font-weight: 800;
}

.discover-rank,
.discover-fresh-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 7;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 27px;
    padding: 5px 9px;
    border: 1px solid rgba(255,255,255,.52);
    border-radius: 4px;
    color: #fff;
    box-shadow: 0 8px 18px rgba(7,25,45,.18), inset 0 1px 0 rgba(255,255,255,.28);
    font-size: .68rem;
    font-weight: 950;
    letter-spacing: .04em;
    line-height: 1;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
}

.discover-rank {
    background: linear-gradient(180deg, #0d64b8, #0054a8);
}

.discover-grid .discover-card:nth-child(1) .discover-rank {
    color: #171100;
    border-color: rgba(255,255,255,.62);
    background: linear-gradient(180deg, #ffe875, #ffc400);
}

.discover-grid .discover-card:nth-child(2) .discover-rank {
    color: #263441;
    background: linear-gradient(180deg, #f5f8fb, #bdcbd8);
}

.discover-grid .discover-card:nth-child(3) .discover-rank {
    color: #fff8ef;
    background: linear-gradient(180deg, #c8864b, #8a4d1f);
}

.discover-fresh-badge {
    color: #07192d;
    background: linear-gradient(180deg, #ffe56c, #ffc400);
}

.discover-empty {
    margin-top: 18px;
    padding: 24px;
    border: 1px solid rgba(0,84,168,.16);
    border-left: 4px solid #ffc400;
    border-radius: 5px;
    background: linear-gradient(135deg, #fff, #eef8ff);
    color: #526f89;
    box-shadow: 0 10px 24px rgba(0,84,168,.08);
    font-weight: 800;
}

/* =========================================================
   Animációk
   ========================================================= */
@keyframes ktDiscoverHeroShine {
    0%, 72%, 100% { transform: translateX(-120%); opacity: 0; }
    78% { opacity: .72; }
    90% { transform: translateX(120%); opacity: 0; }
}

@keyframes ktDiscoverIconHalo {
    0%, 100% { transform: scale(.96); opacity: .35; }
    50% { transform: scale(1.035); opacity: .82; }
}

@keyframes ktDiscoverFireEmoji {
    0%, 100% { transform: translateY(0) scale(1) rotate(-2deg); }
    22% { transform: translateY(-1px) scale(1.04, .98) rotate(2deg); }
    48% { transform: translateY(1px) scale(.98, 1.03) rotate(-3deg); }
    72% { transform: translateY(-1px) scale(1.03) rotate(1deg); }
}

@keyframes ktDiscoverFlameOuter {
    0%, 100% { transform: translateX(-50%) rotate(8deg) scale(1); }
    38% { transform: translateX(-52%) rotate(3deg) scale(.96, 1.04); }
    68% { transform: translateX(-48%) rotate(11deg) scale(1.03, .98); }
}

@keyframes ktDiscoverFlameInner {
    0%, 100% { transform: translateX(-49%) rotate(-7deg) scale(1); }
    45% { transform: translateX(-52%) rotate(-2deg) scale(.94, 1.06); }
    72% { transform: translateX(-47%) rotate(-10deg) scale(1.04, .97); }
}

@keyframes ktDiscoverFlameCore {
    0%, 100% { transform: translateX(-50%) rotate(5deg) scale(1); opacity: .92; }
    50% { transform: translateX(-48%) rotate(-3deg) scale(.88, 1.08); opacity: 1; }
}

@keyframes ktDiscoverSparkOne {
    0%, 72%, 100% { transform: translate(0, 0) scale(.4); opacity: 0; }
    78% { opacity: 1; }
    92% { transform: translate(-8px, -18px) scale(1); opacity: 0; }
}

@keyframes ktDiscoverSparkTwo {
    0%, 72%, 100% { transform: translate(0, 0) scale(.4); opacity: 0; }
    78% { opacity: 1; }
    92% { transform: translate(9px, -16px) scale(1); opacity: 0; }
}

@keyframes ktDiscoverSparkThree {
    0%, 74%, 100% { transform: translate(0, 0) scale(.4); opacity: 0; }
    80% { opacity: .9; }
    93% { transform: translate(4px, -14px) scale(1); opacity: 0; }
}

@keyframes ktDiscoverBoltPulse {
    0%, 72%, 100% { transform: translateY(0) scale(1); filter: drop-shadow(0 0 3px rgba(255,255,255,.8)) drop-shadow(0 8px 10px rgba(0,84,168,.22)); }
    77% { transform: translateY(-1px) scale(1.08); filter: drop-shadow(0 0 7px rgba(255,255,255,1)) drop-shadow(0 0 17px rgba(26,215,239,.56)); }
    82% { transform: translateY(1px) scale(.98); }
    87% { transform: translateY(-1px) scale(1.05); }
}

@keyframes ktDiscoverBoltRing {
    0%, 72%, 100% { transform: scale(.78); opacity: 0; }
    78% { opacity: .52; }
    92% { transform: scale(1.22); opacity: 0; }
}

@keyframes ktDiscoverBoltDot {
    0%, 72%, 100% { transform: scale(.4); opacity: 0; }
    78% { transform: scale(1); opacity: 1; }
    90% { transform: scale(.5) translateY(-9px); opacity: 0; }
}

@keyframes ktDiscoverCardShine {
    from { transform: translateX(-125%); }
    to { transform: translateX(125%); }
}

/* =========================================================
   Reszponzív
   ========================================================= */
@media (max-width: 980px) {
    .discover-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .discover-hero-title-row {
        display: grid;
        gap: 4px;
    }
}

@media (max-width: 660px) {
    .discover-main {
        width: min(100% - 20px, 1440px);
        margin-top: 14px;
    }

    .discover-hero {
        min-height: 96px;
        gap: 12px;
        padding: 13px 12px 13px 14px;
    }

    .discover-hero::after {
        right: 68px;
        top: 12px;
        bottom: 12px;
    }

    .discover-hero h1 {
        font-size: clamp(1.55rem, 8vw, 2rem);
    }

    .discover-hero p:not(.discover-kicker) {
        display: none;
    }

    .discover-hero-icon {
        width: 52px;
        height: 52px;
    }

    .discover-fire-emoji {
        font-size: 24px;
    }

    .discover-bolt {
        transform: scale(.78);
    }

    .discover-grid {
        grid-template-columns: 1fr;
        gap: 14px;
        margin-top: 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .discover-hero::before,
    .discover-hero-icon::after,
    .discover-fire-emoji,
    .discover-bolt-shape,
    .discover-bolt-ring,
    .discover-bolt-dot,
    .discover-card::after {
        animation: none !important;
    }
}
