/* Pagina principală: hero cu personajul 3D, countdown, carduri și instrucțiuni. */

@media (min-width: 641px) {
    .card.scroll-animate:nth-child(2) { transition-delay: 0.15s; }
    .card.scroll-animate:nth-child(3) { transition-delay: 0.3s; }
}

.mobile-break { display: none; }

/* --- Hero --- */
.hero {
    position: relative;
    padding: 160px 0 100px;
    width: 100%;
    min-height: 85vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 2;
}

/* --- Countdown + IP --- */
.topbar-group {
    position: absolute;
    top: -130px;
    right: 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.topbar {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(26, 26, 26, 0.7);
    border: 1px solid rgba(250, 204, 21, 0.25);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 99px;
    padding: 12px 30px;
    box-shadow: inset 0 1px rgba(255, 255, 255, 0.1), 0 4px 20px rgba(0, 0, 0, 0.5);
}

.topbar-label {
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-sec);
}

.topbar-countdown {
    display: flex;
    align-items: center;
    gap: 6px;
}

.tcd-num {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.8rem;
    color: var(--text-main);
    line-height: 1;
    min-width: 24px;
    text-align: center;
}

.tcd-num.live { color: var(--accent); }

.tcd-sep {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
}

.server-info-group {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 1px;
    color: var(--text-sec);
    margin-right: 20px;
}

.server-info-dot { color: rgba(255, 255, 255, 0.3); }

.copy-ip {
    background: none;
    border: none;
    font: inherit;
    letter-spacing: inherit;
    color: var(--accent);
    cursor: pointer;
    transition: color 0.2s ease, text-shadow 0.2s ease;
}

.copy-ip:hover {
    color: var(--text-main);
    text-shadow: 0 0 10px rgba(250, 204, 21, 0.6);
}

.copy-ip.copied { color: #4ade80; }

/* --- Personajul 3D --- */
.hero-character {
    position: relative;
    height: 480px;
    width: 31%;
    max-width: 340px;
    flex-shrink: 0;
    pointer-events: none;
    filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.8));
}

.hero-character::before {
    content: "";
    position: absolute;
    inset: 3% -18% 0;
    border-radius: 50%;
    mask-image: radial-gradient(ellipse, black 25%, transparent 72%);
    filter: blur(12px);
    background: radial-gradient(ellipse at 78% 16%, rgba(255, 207, 91, 0.18), rgba(250, 190, 55, 0.045) 40%, transparent 68%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.hero-character::after {
    content: "";
    position: absolute;
    left: 18%;
    right: 14%;
    bottom: 6%;
    height: 24px;
    background: radial-gradient(ellipse, rgba(250, 190, 55, 0.12), transparent 70%);
    filter: blur(7px);
    opacity: 0;
    pointer-events: none;
}

.hero-character.is-ready::before,
.hero-character.is-ready::after { opacity: 1; }

.hero-character-fallback,
.hero-character-canvas {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    transition: opacity 0.3s ease;
}

.hero-character-fallback { object-fit: contain; }
.hero-character-canvas { opacity: 0; z-index: 1; }
.hero-character.is-ready .hero-character-canvas { opacity: 1; }
.hero-character.is-ready .hero-character-fallback { opacity: 0; }

/* --- Text + buton --- */
.hero-content-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
    max-width: 650px;
}

.hero-text-group {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.hero-text-group h1 {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 8rem;
    font-weight: 400;
    line-height: 0.9;
    margin-bottom: 10px;
    letter-spacing: 2px;
    text-shadow: 0 10px 40px rgba(0, 0, 0, 1);
}

.hero-subtitle {
    color: var(--text-sec);
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 40px;
    letter-spacing: 0.5px;
}

@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 0 15px rgba(250, 204, 21, 0.2); }
    50% { box-shadow: 0 0 35px rgba(250, 204, 21, 0.7); }
}

.download-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background-color: var(--accent);
    color: var(--bg-main);
    font-size: 1.3rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    text-decoration: none;
    padding: 20px 50px;
    border-radius: 14px;
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    animation: pulseGlow 2.5s infinite;
    width: fit-content;
}

.download-btn:hover {
    background-color: var(--text-main);
    transform: translateY(-4px) scale(1.01);
    box-shadow: 0 15px 40px rgba(250, 204, 21, 1);
}

/* --- Carduri --- */
.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 25px;
    margin: 60px auto;
    position: relative;
    z-index: 2;
}

.card {
    background-color: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 30px;
    border-radius: 18px;
    transition: opacity 0.8s ease-out, transform 0.8s ease-out, border-color 0.4s ease, box-shadow 0.4s ease;
}

.card:hover {
    transform: translateY(-8px);
    border-color: rgba(250, 204, 21, 0.3);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
}

.card h3 {
    color: var(--accent);
    margin-bottom: 12px;
    font-size: 1.35rem;
    font-weight: 600;
}

.feature-icon {
    display: inline-block;
    vertical-align: -0.2em;
    margin-right: 6px;
}

.card p {
    color: var(--text-sec);
    font-size: 0.98rem;
}

/* --- Instrucțiuni --- */
.instructions {
    margin: 20px auto 80px;
    background-color: var(--bg-sec);
    padding: 40px;
    border-radius: 18px;
    border: 1px solid var(--border);
    position: relative;
    z-index: 2;
}

.instructions h2 {
    text-align: center;
    margin-bottom: 35px;
    font-weight: 800;
    font-size: 1.8rem;
}

.step {
    margin-bottom: 22px;
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.step-number {
    background-color: var(--accent);
    color: var(--bg-main);
    font-weight: 800;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    flex-shrink: 0;
    font-size: 1.1rem;
}

.step-text {
    padding-top: 6px;
    font-size: 1.05rem;
}

.step-text strong {
    color: var(--accent);
    font-weight: 600;
}

.warning {
    margin-top: 30px;
    padding: 20px;
    background-color: rgba(239, 68, 68, 0.08);
    border-left: 4px solid var(--danger);
    color: #fca5a5;
    font-size: 0.95rem;
    border-radius: 0 12px 12px 0;
}

/* --- Mobil și tabletă --- */
@media (max-width: 900px) {
    .mobile-break { display: block; }

    .hero {
        padding: 125px 0 50px;
        min-height: calc(100svh - 65px);
        align-items: flex-end;
    }

    .hero-inner {
        flex-direction: column;
        position: static;
        width: 100%;
    }

    .topbar-group {
        top: 20px;
        right: 10px;
        gap: 5px;
    }

    .topbar { padding: 8px 15px; gap: 8px; }
    .topbar-label { font-size: 0.65rem; letter-spacing: 1px; }
    .tcd-num { font-size: 1.2rem; min-width: 15px; }
    .tcd-sep { font-size: 1rem; }
    .server-info-group { font-size: 0.8rem; margin-right: 15px; gap: 5px; }

    /* Pe telefon personajul stă deasupra titlului, în locul golului din hero. */
    .hero-character {
        width: min(55vw, 230px);
        height: min(31svh, 295px);
        max-width: none;
        margin: 0 auto 18px;
    }

    .hero-content-right {
        align-items: center;
        max-width: 100%;
    }

    .hero-text-group {
        width: max-content;
        max-width: 100%;
    }

    .hero-text-group h1 {
        font-size: 4.5rem;
        line-height: 1;
        text-shadow: 0 5px 20px rgba(0, 0, 0, 1);
    }

    .hero-subtitle {
        font-size: 1.1rem;
        margin-bottom: 30px;
        text-align: right;
    }

    .download-btn {
        width: 100%;
        padding: 18px 20px;
        font-size: 1.1rem;
    }

    .features { grid-template-columns: 1fr; margin: 30px auto; }
    .instructions { margin: 10px auto 40px; padding: 25px 20px; }
}

@media (prefers-reduced-motion: reduce) {
    .hero-character-fallback,
    .hero-character-canvas,
    .hero-character::before { transition: none; }
    .download-btn { animation: none; }
}
