/* ============================================================
   HOW TO PLAY — Sharp Edges Design (NO border-radius)
   ============================================================ */

:root {
    --gold: #f2cf5b;
    --gold-dark: #c9a227;
    --gold-deep: #8a6a14;
    --gold-light: #fde68a;
    --text-light: rgba(255,255,255,0.88);
    --text-muted: rgba(255,255,255,0.5);
    --text-dim: rgba(255,255,255,0.2);
}

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: rgba(6,9,14,0.9); }
::-webkit-scrollbar-thumb { background: linear-gradient(180deg, #f6d478, #c9a227, #8a6a14); }
::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, #f6d478, #d4a82a, #9b7a18); }
* {scrollbar-width: thin;scrollbar-color: #96989f rgb(40 45 60);}

/* --- Container — NO border-radius --- */
.az-wrap {
    max-width: 1600px;
    margin: 30px auto 0;
    padding: 30px 30px 40px;
    background: linear-gradient(180deg, rgba(40, 45, 60), rgba(40, 45, 60));
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgb(167 169 176);
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
    position: relative;
    z-index: 2;
    border-radius: 4px;
}

.az-wrap::before {
    content: '';
    position: absolute;
    inset: 6px;
    border: 1px solid rgb(157 159 166 / 22%);
    pointer-events: none;
}

.az-wrap::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(#d5ad4a, #d5ad4a) left top / 16px 1px,
        linear-gradient(#d5ad4a, #d5ad4a) left top / 1px 16px,
        linear-gradient(#d5ad4a, #d5ad4a) right top / 16px 1px,
        linear-gradient(#d5ad4a, #d5ad4a) right top / 1px 16px,
        linear-gradient(#d5ad4a, #d5ad4a) left bottom / 16px 1px,
        linear-gradient(#d5ad4a, #d5ad4a) left bottom / 1px 16px,
        linear-gradient(#d5ad4a, #d5ad4a) right bottom / 16px 1px,
        linear-gradient(#d5ad4a, #d5ad4a) right bottom / 1px 16px;
    background-repeat: no-repeat;
    opacity: 0.12;
}

@media (max-width: 768px) {
    .az-wrap {
        padding: 16px 16px 30px;
        margin: 20px 8px 0;
    }
}

@media (max-width: 480px) {
    .az-wrap {
        padding: 10px 10px 24px;
        margin: 16px 4px 0;
    }
}

/* --- Background --- */
body.how_to_play {
    background: 
        radial-gradient(ellipse at 50% 0%, rgba(242,207,82,0.05) 0%, transparent 60%),
        radial-gradient(ellipse at 30% 100%, rgba(139,92,246,0.03) 0%, transparent 40%),
        radial-gradient(ellipse at 70% 100%, rgba(59,130,246,0.03) 0%, transparent 40%),
        url('https://azerion.world/img/backgrounds/bg-howto.jpg') no-repeat center center fixed !important;
    background-size: cover !important;
    min-height: 100vh;
    position: relative;
    padding-top: 80px;
    margin: 0;
    overflow-x: hidden;
}

body.how_to_play::before {
    content: '';
    position: fixed;
    inset: 0;
    background: linear-gradient(180deg, 
        rgba(3,5,10,0.2) 0%, 
        rgba(3,5,10,0.5) 50%,
        rgba(3,5,10,0.85) 100%
    );
    z-index: 0;
    pointer-events: none;
}

body.how_to_play::after {
    content: '';
    position: fixed;
    inset: 0;
    background: 
        radial-gradient(2px 2px at 15% 25%, rgba(242,207,82,0.2), transparent),
        radial-gradient(2px 2px at 35% 55%, rgba(242,207,82,0.12), transparent),
        radial-gradient(2px 2px at 55% 15%, rgba(242,207,82,0.15), transparent),
        radial-gradient(1px 1px at 90% 35%, rgba(242,207,82,0.2), transparent);
    background-size: 100% 100%;
    z-index: 0;
    pointer-events: none;
    animation: sparkleFloat 14s ease-in-out infinite alternate;
}

@keyframes sparkleFloat {
    0% { opacity: 0.2; }
    50% { opacity: 0.5; }
    100% { opacity: 0.2; }
}

/* --- Hero Section --- */
.hero-section {
    position: relative;
    z-index: 2;
    padding: 0 0 20px;
    text-align: center;
}

.hero-title {
    font-family: 'Inter', sans-serif;
    font-weight: 900;
    font-size: clamp(2rem, 6vw, 4rem);
    line-height: 1.05;
    color: transparent;
    filter: drop-shadow(0 8px 40px rgba(0,0,0,0.9));
    text-transform: uppercase;
    letter-spacing: -0.02em;
    margin: 0 0 12px;
    padding: 0 4px;
    background: rgb(161 163 170);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 5px 0 #282d3c) drop-shadow(0 10px 20px #000);
}

.hero-title::after {
    content: '⚔';
    position: relative;
    display: inline-block;
    font-size: 1.5rem;
    opacity: 0.12;
    margin-left: 8px;
}

@media (min-width: 600px) {
    .hero-title::after {
        position: absolute;
        right: -45px;
        top: 5%;
        font-size: 2.2rem;
        opacity: 0.06;
    }
}

.hero-subtitle {
    font-family: 'Inter', sans-serif;
    font-size: clamp(0.9rem, 1.2vw, 1.15rem);
    color: rgba(255,255,255,0.35);
    max-width: 620px;
    margin: 0 auto;
    line-height: 1.8;
    font-weight: 300;
    text-shadow: 0 2px 24px rgba(0,0,0,0.8);
}

.hero-subtitle .gold-highlight {
    color: var(--gold);
    font-weight: 600;
    text-shadow: 0 0 40px rgba(242,207,82,0.05);
}

/* --- Divider with runes --- */
.divider-runes {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    max-width: 300px;
    margin: 0 auto 16px;
}

.divider-runes .line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgb(255 255 255 / 15%), transparent);
}

.divider-runes .rune-symbol {
    color: rgb(255 255 255 / 12%);
    font-size: 0.5rem;
    letter-spacing: 4px;
    font-weight: 300;
    white-space: nowrap;
}

@media (min-width: 768px) {
    .divider-runes { max-width: 400px; gap: 14px; }
    .divider-runes .rune-symbol { font-size: 0.65rem; letter-spacing: 6px; }
}

/* --- Step Cards — NO border-radius --- */
.step-card {
    position: relative;
    background: linear-gradient(160deg, rgb(50 55 69), rgb(51 56 70));
    border: 1px solid rgba(201,162,39,0.04);
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
    transition: all 0.4s ease;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    border-radius: 4px;
}

/* Top gold glow line */
.step-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #878a93, transparent);
    opacity: 0.15;
    transition: opacity 0.4s ease;
}

.step-card:hover::before {
    opacity: 0.7;
}

.step-card:hover {
    transform: translateY(-6px);
    border-color: rgb(157 159 165);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

/* --- Step Number — NO border-radius (Sharp shield) --- */
.step-number-wrap {
    position: absolute;
    top: -16px;
    left: 20px;
    z-index: 5;
    width: 48px;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #a1a3aa 0%, #a1a3aa 50%, #282d3c 100%);
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    box-shadow: 0 8px 28px rgba(0,0,0,0.5);
    color: #1a1200;
    font-family: 'Inter', sans-serif;
    font-weight: 900;
    font-size: 1.2rem;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.15);
    transition: all 0.4s ease;
}

.step-card:hover .step-number-wrap {
    transform: scale(1.06) rotate(-4deg);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 50px rgba(242, 207, 82, 0.1);
}

.step-number {
    position: relative;
    z-index: 2;
    margin-top: -4px;
}

/* Shield glow ring */
.step-number-wrap::after {
    content: '';
    position: absolute;
    inset: -4px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    border: 1px solid rgb(0 0 0);
    animation: shieldPulse 3s ease-in-out infinite;
}

@keyframes shieldPulse {
    0%, 100% { transform: scale(1); opacity: 0.3; }
    50% { transform: scale(1.08); opacity: 0; }
}

@media (min-width: 500px) {
    .step-number-wrap { width: 54px; height: 60px; font-size: 1.4rem; top: -18px; left: 24px; }
}

@media (min-width: 768px) {
    .step-number-wrap { width: 56px; height: 62px; }
}

/* --- Image Area --- */
.step-image-wrap {
    padding: 28px 20px 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    min-height: 160px;
    background: linear-gradient(145deg, rgba(50, 55, 70, .97), rgba(50, 55, 70, .98));
}

.step-image {
    max-width: 280px;
    width: 100%;
    max-height: 220px;
    object-fit: contain;
    padding: 4px;
    background: rgba(0,0,0,0.15);
    border: 1px solid rgba(201,162,39,0.03);
    transition: all 0.5s ease;
    filter: drop-shadow(0 8px 20px rgba(0,0,0,0.2));
}

.step-card:hover .step-image {
    transform: scale(1.03);
    border-color: rgba(201,162,39,0.06);
}

@media (min-width: 500px) {
    .step-image-wrap { padding: 34px 24px 8px; min-height: 200px; }
    .step-image { max-width: 360px; max-height: 280px; }
}

@media (min-width: 768px) {
    .step-image { max-height: 300px; }
}

/* --- Content --- */
.step-content {
    padding: 4px 18px 18px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.step-title {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.02em;
    text-shadow: 0 2px 12px rgba(0,0,0,0.8);
    margin-bottom: 2px;
}

.step-desc {
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
    line-height: 1.7;
}

.step-desc-light {
    color: rgba(255,255,255,0.25);
    font-size: 0.8rem;
    line-height: 1.6;
}

@media (min-width: 500px) {
    .step-content { padding: 8px 24px 24px; }
    .step-title { font-size: 1.15rem; }
    .step-desc { font-size: 0.9rem; }
}

@media (min-width: 768px) {
    .step-title { font-size: 1.2rem; }
}

/* --- Buttons — NO border-radius --- */
.btn-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 20px;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.35s ease;
    border: none;
    cursor: pointer;
    width: 100%;
    position: relative;
    overflow: hidden;
}

.btn-action::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.06), transparent 50%);
    pointer-events: none;
}

.btn-action:hover {
    transform: translateY(-2px);
}

.btn-gold {
    background: linear-gradient(180deg, #2d3240 0%, #2c3140 45%, #2c3140 100%);
    color: #ffffff;
    box-shadow: 0 4px 20px rgb(161 163 170 / 10%);
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.12);
    border: solid 1px #9d9fa552;
    border-radius: 4px;
}

.btn-gold:hover {
    box-shadow: 0 8px 40px rgb(255 255 255 / 15%);
    filter: brightness(1.05);
}

.btn-iron {
    /* background: linear-gradient(180deg, #3a404d 0%, #232833 55%, #141821 100%); */
    /* color: #cfe1ff; */
    /* box-shadow: 0 4px 16px rgba(0,0,0,0.3); */
    background: linear-gradient(180deg, #2d3240 0%, #2c3140 45%, #2c3140 100%);
    color: #ffffff;
    box-shadow: 0 4px 20px rgb(161 163 170 / 10%);
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.12);
    border: solid 1px #9d9fa552;
    border-radius: 4px;
}

.btn-iron:hover {
    box-shadow: 0 8px 32px rgba(59,130,246,0.06);
    filter: brightness(1.06);
}

.btn-iron .icon-cyan { color: #22d3ee; }
.btn-iron .icon-amber { color: #fbbf24; }

@media (min-width: 500px) {
    .btn-action { padding: 14px 24px; font-size: 0.75rem; }
}

/* --- Code Box — NO border-radius --- */
.code-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(0,0,0,0.5);
    border: 1px solid rgba(201,162,39,0.04);
    font-family: 'Inter', monospace;
    font-size: 0.7rem;
    margin-top: 8px;
}

.code-box code {
    color: #4ade80;
    font-weight: 500;
    overflow-x: auto;
    white-space: nowrap;
    font-family: 'Inter', monospace;
}

.code-box code .gold-text {
    color: #ffffff;
    font-weight: 700;
}

.copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255,255,255,0.03);
    color: rgba(255, 255, 255, 0.2);
    font-family: 'Inter', sans-serif;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.copy-btn:hover {
    background: rgba(242,207,82,0.04);
    border-color: rgba(242,207,82,0.06);
    color: var(--gold);
}

.copy-btn.copied {
    background: rgba(74,222,128,0.04);
    border-color: rgba(74,222,128,0.06);
    color: #4ade80;
}

.copy-btn svg {
    width: 12px;
    height: 12px;
}

.copy-hint {
    font-size: 0.6rem;
    color: rgb(165 165 165);
    margin-top: 4px;
    font-style: italic;
}

@media (min-width: 500px) {
    .code-box { padding: 10px 14px; font-size: 0.8rem; }
    .copy-btn { font-size: 0.65rem; padding: 5px 14px; }
    .copy-btn svg { width: 13px; height: 13px; }
}

@media (max-width: 480px) {
    .code-box { flex-direction: column; align-items: stretch; gap: 6px; }
    .code-box code { font-size: 0.65rem; text-align: center; }
    .copy-btn { justify-content: center; padding: 6px; }
}

/* --- Ready Badge --- */
.ready-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    padding: 5px 16px 5px 10px;
    background: rgba(74,222,128,0.04);
    border: 1px solid rgba(74,222,128,0.04);
    color: #4ade80;
    font-family: 'Inter', sans-serif;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    align-self: flex-start;
}

.ready-badge .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #4ade80;
    animation: pulseDot 2s ease-in-out infinite;
}

@keyframes pulseDot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.3; transform: scale(0.7); }
}

@media (min-width: 500px) {
    .ready-badge { font-size: 0.7rem; padding: 6px 18px 6px 12px; }
    .ready-badge .dot { width: 7px; height: 7px; }
}

/* --- CTA Panel — NO border-radius --- */
.cta-panel {
    position: relative;
    background: linear-gradient(145deg, rgba(50, 55, 70, .97), rgba(50, 55, 70, .98));
    border: 1px solid rgba(201,162,39,0.04);
    padding: 32px 20px;
    box-shadow: 0 16px 48px rgba(0,0,0,0.4);
    overflow: hidden;
}

.cta-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 30% 50%, rgba(242,207,82,0.03), transparent 60%);
    pointer-events: none;
}

.cta-panel::after {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid rgba(201,162,39,0.02);
    pointer-events: none;
}

.cta-title {
    font-family: 'Inter', sans-serif;
    font-size: clamp(1.4rem, 3vw, 2.4rem);
    font-weight: 900;
    color: rgba(255,255,255,0.9);
    text-shadow: 0 2px 24px rgba(0,0,0,0.8);
    letter-spacing: -0.01em;
}

.cta-title .gold-text {
    background: linear-gradient(180deg, #ffffff, #ffffff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.cta-desc {
    color: rgb(255 255 255 / 54%);
    font-size: clamp(0.85rem, 1vw, 1rem);
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.8;
}

@media (min-width: 500px) {
    .cta-panel { padding: 40px 30px; }
}

@media (min-width: 768px) {
    .cta-panel { padding: 50px 40px; }
}

/* --- Animations --- */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(25px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-up {
    animation: fadeUp 0.6s ease forwards;
    opacity: 0;
}

.fade-up-1 { animation-delay: 0.05s; }
.fade-up-2 { animation-delay: 0.15s; }
.fade-up-3 { animation-delay: 0.25s; }
.fade-up-4 { animation-delay: 0.35s; }
.fade-up-5 { animation-delay: 0.5s; padding-top: 20px; }

.step-card {
    opacity: 0;
    animation: none;
}

.step-card.visible {
    animation: fadeUp 0.6s ease forwards;
}

/* --- Grid gap --- */
.grid-gap {
    gap: 16px;
}

@media (min-width: 768px) {
    .grid-gap { gap: 24px; }
}

@media (min-width: 1024px) {
    .grid-gap {gap: 20px;}
}

/* --- Responsive --- */
@media (max-width: 480px) {
    .step-image-wrap { min-height: 120px; padding: 20px 8px 4px; }
    .step-image { max-height: 160px; max-width: 200px; }
    .step-number-wrap { width: 36px; height: 42px; font-size: 0.9rem; top: -12px; left: 14px; }
    .step-title { font-size: 0.9rem; }
    .step-desc { font-size: 0.75rem; }
    .step-content { padding: 4px 14px 14px; }
    .btn-action { font-size: 0.6rem; padding: 10px 14px; }
    .cta-panel { padding: 20px 12px; }
    .cta-title { font-size: 1.2rem; }
    .hero-title { font-size: 1.6rem; }
    .hero-title::after { font-size: 1rem; margin-left: 4px; }
}