/*
Theme Name: DmFirst
Theme URI: https://dmfirstgames.club/
Author: DmFirst
Description: DmFirst premium green and gold single-page WordPress theme.
Version: 1.0.0
Text Domain: dmfirst
*/

/* ============================================================
   DMFIRST — DEEP DARK PREMIUM GREEN + GOLDEN BUTTONS
   ============================================================ */
:root {
    --green-darkest: #021a12;
    --green-dark: #042b1e;
    --green-premium: #063a29;
    --green-mid: #0a4d38;
    --green-accent: #0e6248;
    --green-light: #d1f0e0;

    --white: #ffffff;
    --off-white: #f5faf7;
    --gray-text: #4b5f55;
    --gray-dark: #1a2820;
    --border: #d0e5da;

    --shadow: 0 2px 12px rgba(2, 26, 18, 0.08);
    --shadow-md: 0 6px 24px rgba(2, 26, 18, 0.15);
    --shadow-lg: 0 12px 40px rgba(2, 26, 18, 0.2);

    --radius: 12px;
    --radius-sm: 8px;

    --gold: #d4a017;
    --gold-light: #f0c040;
    --gold-dark: #b8860b;
    --gold-gradient: linear-gradient(135deg, #f5cf4e, #d4a017);
    --gold-gradient-hover: linear-gradient(135deg, #ffdb6e, #e6b32a);
    --shadow-gold: 0 4px 18px rgba(212, 160, 23, 0.4);
    --shadow-gold-hover: 0 8px 28px rgba(212, 160, 23, 0.55);
}

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

html { scroll-behavior: smooth; }

body {
    font-family: 'Poppins', 'Segoe UI', system-ui, sans-serif;
    background: var(--white);
    color: var(--gray-dark);
    line-height: 1.7;
    font-size: 16px;
}

a { text-decoration: none; color: var(--green-accent); transition: color 0.2s; }
a:hover { color: var(--gold); }

img { max-width: 100%; height: auto; display: block; }

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== HEADER ===== */
.site-header {
    background: var(--green-darkest);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.4);
    border-bottom: 1px solid rgba(212, 160, 23, 0.15);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 14px;
}

/* ===== LOGO STYLES ===== */
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: opacity 0.2s;
}

.brand:hover { opacity: 0.9; }

.logo-img {
    height: 40px;
    width: auto;
    display: block;
}

/* Fallback text if logo doesn't load */
.brand-text {
    font-size: 24px;
    font-weight: 800;
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.3px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 22px;
    flex-wrap: wrap;
}

.nav-links a {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    cursor: pointer;
}

.nav-links a:hover { color: var(--gold-light); }

.btn-register {
    background: var(--gold-gradient);
    color: #1f1a15 !important;
    padding: 9px 26px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 14px;
    box-shadow: var(--shadow-gold);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    cursor: pointer;
    display: inline-block;
}

.btn-register:hover {
    background: var(--gold-gradient-hover);
    transform: translateY(-1px);
    box-shadow: var(--shadow-gold-hover);
}

/* ===== HERO ===== */
.hero {
    background: linear-gradient(135deg, var(--green-darkest) 0%, var(--green-dark) 40%, var(--green-premium) 100%);
    color: var(--white);
    padding: 80px 0 70px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(212, 160, 23, 0.08), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(14, 98, 72, 0.25), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.hero h1 {
    font-size: 44px;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
    color: var(--white);
    position: relative;
    z-index: 1;
}

.hero h1 span {
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    font-size: 17px;
    color: rgba(255, 255, 255, 0.85);
    max-width: 800px;
    margin: 0 auto 34px;
    position: relative;
    z-index: 1;
}

.hero-buttons {
    display: flex;
    gap: 14px;
    justify-content: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.btn-primary {
    padding: 14px 34px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 15px;
    background: var(--gold-gradient);
    color: #1f1a15;
    box-shadow: var(--shadow-gold);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    display: inline-block;
    cursor: pointer;
    border: none;
}

.btn-primary:hover {
    background: var(--gold-gradient-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-gold-hover);
}

.btn-secondary {
    padding: 14px 34px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 15px;
    background: transparent;
    color: var(--gold-light);
    border: 2px solid var(--gold);
    transition: background 0.2s, color 0.2s, transform 0.2s;
    display: inline-block;
    cursor: pointer;
}

.btn-secondary:hover {
    background: var(--gold-gradient);
    color: #1f1a15;
    border-color: var(--gold);
    transform: translateY(-2px);
}

/* ===== TOC ===== */
.toc {
    background: var(--off-white);
    border: 1px solid var(--border);
    border-left: 4px solid var(--gold);
    border-radius: var(--radius);
    padding: 24px 28px;
    margin: 40px auto;
    max-width: 900px;
    box-shadow: var(--shadow);
}

.toc h2 {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 14px;
    color: var(--green-premium);
}

.toc ol {
    padding-left: 22px;
    columns: 2;
    column-gap: 30px;
}

.toc li {
    padding: 3px 0;
    font-size: 14px;
    color: var(--gray-text);
    break-inside: avoid;
}

.toc a { color: var(--gray-text); cursor: pointer; }
.toc a:hover { color: var(--green-accent); }

/* ===== SECTIONS ===== */
.section {
    padding: 48px 0;
    border-bottom: 1px solid var(--border);
}

.section:last-of-type { border-bottom: none; }

.section h2 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--green-premium);
    position: relative;
    padding-left: 16px;
}

.section h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 6px;
    bottom: 6px;
    width: 4px;
    background: var(--gold-gradient);
    border-radius: 4px;
}

.section h3 {
    font-size: 21px;
    font-weight: 600;
    margin: 24px 0 12px;
    color: var(--green-mid);
}

.section h4 {
    font-size: 17px;
    font-weight: 600;
    margin: 18px 0 10px;
    color: var(--green-premium);
}

.section p {
    color: var(--gray-text);
    margin-bottom: 14px;
}

.section ul, .section ol {
    padding-left: 22px;
    margin-bottom: 18px;
}

.section li {
    color: var(--gray-text);
    padding: 4px 0;
}

.section strong { color: var(--green-premium); }

/* ===== TABLE ===== */
.table-wrap {
    overflow-x: auto;
    margin: 20px 0;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
}

th, td {
    padding: 14px 18px;
    text-align: left;
    font-size: 15px;
    border-bottom: 1px solid var(--border);
}

th {
    background: var(--green-darkest);
    font-weight: 700;
    color: var(--gold-light);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

td { color: var(--gray-text); }

tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--off-white); }

/* ===== CARDS ===== */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
    margin: 24px 0;
}

.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow);
    transition: transform 0.2s, box-shadow 0.2s;
    border-top: 3px solid var(--gold);
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.card h3, .card h4 {
    margin-top: 0;
    color: var(--green-premium);
    font-size: 18px;
}

.card p {
    margin-bottom: 0;
    font-size: 15px;
    color: var(--gray-text);
}

/* ===== COLOR BADGES ===== */
.color-badge {
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    display: inline-block;
}

.color-green { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.color-red { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.color-violet { background: #ede9fe; color: #5b21b6; border: 1px solid #c4b5fd; }

/* ===== FAQ ===== */
.faq-list { margin: 24px 0; }

.faq-item {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
    overflow: hidden;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.faq-item:hover { border-color: var(--gold); }
.faq-item.active { border-color: var(--gold); box-shadow: var(--shadow-md); }

.faq-q {
    padding: 18px 22px;
    font-weight: 600;
    font-size: 16px;
    color: var(--green-premium);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    user-select: none;
}

.faq-q .icon {
    font-size: 22px;
    color: var(--gold-dark);
    transition: transform 0.3s;
    flex-shrink: 0;
    font-weight: 400;
}

.faq-item.active .faq-q .icon { transform: rotate(45deg); }

.faq-a {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
    padding: 0 22px;
    color: var(--gray-text);
    font-size: 15px;
}

.faq-item.active .faq-a {
    max-height: 400px;
    padding: 0 22px 18px;
}

/* ===== NOTICE ===== */
.notice {
    background: var(--green-light);
    border-left: 4px solid var(--gold);
    border-radius: var(--radius-sm);
    padding: 18px 22px;
    margin: 24px 0;
    color: var(--gray-dark);
    font-size: 15px;
}

.notice strong { color: var(--green-premium); }

/* ===== INLINE GOLDEN BUTTON ===== */
.btn-inline {
    display: inline-block;
    background: var(--gold-gradient);
    color: #1f1a15;
    padding: 13px 34px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 15px;
    margin: 16px 0;
    box-shadow: var(--shadow-gold);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    cursor: pointer;
    border: none;
}

.btn-inline:hover {
    background: var(--gold-gradient-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-gold-hover);
}

/* ===== FOOTER ===== */
.site-footer {
    background: var(--green-darkest);
    color: rgba(255, 255, 255, 0.8);
    padding: 50px 0 24px;
    margin-top: 40px;
    border-top: 1px solid rgba(212, 160, 23, 0.15);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 36px;
}

.footer-col h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--gold-light);
    margin-bottom: 14px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer-col a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    padding: 5px 0;
    transition: color 0.2s;
    cursor: pointer;
}

.footer-col a:hover { color: var(--gold-light); }

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding-top: 22px;
    text-align: center;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.footer-bottom strong { color: var(--gold-light); }

/* ===== BACK TO TOP ===== */
.back-to-top {
    position: fixed;
    bottom: 28px;
    right: 28px;
    width: 48px;
    height: 48px;
    border-radius: 10px;
    background: var(--gold-gradient);
    color: #1f1a15;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 700;
    box-shadow: var(--shadow-gold);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s, transform 0.3s, background 0.2s;
    z-index: 999;
    cursor: pointer;
    border: none;
}

.back-to-top.show { opacity: 1; pointer-events: auto; }
.back-to-top:hover {
    transform: translateY(-3px);
    background: var(--gold-gradient-hover);
    box-shadow: var(--shadow-gold-hover);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .hero h1 { font-size: 28px; }
    .hero p { font-size: 15px; }
    .section h2 { font-size: 23px; }
    .section h3 { font-size: 18px; }
    .logo-img { height: 32px; }
    .brand-text { font-size: 20px; }
    .nav-links { gap: 14px; }
    .nav-links a { font-size: 13px; }
    .btn-register { padding: 7px 16px; font-size: 13px; }
    .toc ol { columns: 1; }
    th, td { padding: 11px 12px; font-size: 14px; }
    .hero { padding: 50px 0 40px; }
}

@media (max-width: 480px) {
    .header-inner { flex-direction: column; text-align: center; }
    .nav-links { justify-content: center; }
    .section { padding: 34px 0; }
}
