/* ============================================================
   Adam on Tech — modern dark theme
   ============================================================ */

:root {
    --bg:        #0a0e1a;
    --bg-soft:   #111729;
    --panel:     #151c33;
    --panel-2:   #1b2440;
    --border:    #243056;
    --text:      #e7ecff;
    --text-dim:  #94a0c4;
    --brand:     #0948a1;
    --accent:    #4cc9ff;
    --accent-2:  #8a5cff;
    --accent-3:  #00ffa3;
    --danger:    #ff5577;
    --radius:    14px;
    --radius-lg: 22px;
    --shadow:    0 20px 60px -20px rgba(0,0,0,.6);
    --font:      ui-sans-serif, system-ui, -apple-system, "Segoe UI", Inter, Roboto, sans-serif;
    --mono:      ui-monospace, "JetBrains Mono", "Fira Code", Menlo, monospace;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

body {
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

a { color: var(--accent); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--accent-3); }

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

h1, h2, h3, h4 {
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
    margin: 0 0 .5em;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

.container {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 2;
}

/* ---------- background fx ---------- */

.bg-grid {
    position: fixed; inset: 0;
    background-image:
        linear-gradient(rgba(76, 201, 255, .05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(76, 201, 255, .05) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse at center, #000 40%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse at center, #000 40%, transparent 80%);
    z-index: 0;
    pointer-events: none;
}
.bg-glow {
    position: fixed;
    width: 700px; height: 700px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: .35;
    z-index: 0;
    pointer-events: none;
}
.bg-glow-1 {
    background: radial-gradient(circle, #0948a1 0%, transparent 70%);
    top: -250px; left: -200px;
}
.bg-glow-2 {
    background: radial-gradient(circle, #8a5cff 0%, transparent 70%);
    bottom: -300px; right: -250px;
}

/* ---------- header / nav ---------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    background: rgba(10, 14, 26, .72);
    border-bottom: 1px solid var(--border);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 24px;
    gap: 20px;
}
.brand img {
    height: 48px;
    width: auto;
    filter: drop-shadow(0 4px 12px rgba(76,201,255,.25));
}
.site-nav {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}
.site-nav a {
    color: var(--text-dim);
    font-weight: 600;
    font-size: .95rem;
    padding: 10px 14px;
    border-radius: 10px;
    transition: all .15s ease;
}
.site-nav a:hover { color: var(--text); background: rgba(76,201,255,.08); }
.site-nav a.active {
    color: var(--text);
    background: linear-gradient(135deg, rgba(9,72,161,.5), rgba(138,92,255,.35));
    box-shadow: inset 0 0 0 1px rgba(76,201,255,.3);
}

.nav-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 10px;
    cursor: pointer;
}
.nav-toggle span {
    display: block;
    width: 22px; height: 2px;
    background: var(--text);
    margin: 4px 0;
    border-radius: 2px;
}

@media (max-width: 760px) {
    .nav-toggle { display: block; }
    .site-nav {
        position: absolute;
        top: 100%; left: 0; right: 0;
        flex-direction: column;
        background: rgba(17, 23, 41, .98);
        padding: 12px 24px 20px;
        border-bottom: 1px solid var(--border);
        display: none;
    }
    body.nav-open .site-nav { display: flex; }
    .site-nav a { width: 100%; }
}

/* ---------- hero ---------- */

.hero {
    padding: 80px 0 60px;
    text-align: left;
}
.hero .eyebrow {
    display: inline-block;
    font-family: var(--mono);
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .15em;
    color: var(--accent);
    padding: 6px 12px;
    border: 1px solid rgba(76,201,255,.3);
    border-radius: 999px;
    margin-bottom: 22px;
    background: rgba(76,201,255,.05);
}
.hero h1 {
    background: linear-gradient(135deg, #fff 0%, #4cc9ff 50%, #8a5cff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.hero p.lead {
    font-size: 1.2rem;
    color: var(--text-dim);
    max-width: 640px;
}
.cta-row {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 28px;
}
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 1rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn-primary {
    background: linear-gradient(135deg, #0948a1, #8a5cff);
    color: #fff;
    box-shadow: 0 10px 30px -10px rgba(138,92,255,.6);
}
.btn-primary:hover { transform: translateY(-2px); color: #fff; }
.btn-ghost {
    background: rgba(255,255,255,.04);
    color: var(--text);
    border-color: var(--border);
}
.btn-ghost:hover { background: rgba(76,201,255,.1); color: var(--text); }

/* ---------- highlight cards ---------- */

.highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 22px;
    margin: 60px 0 80px;
}
.card {
    background: linear-gradient(160deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 26px;
    position: relative;
    overflow: hidden;
    transition: transform .2s ease, border-color .2s ease;
}
.card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(76,201,255,.12), transparent 50%);
    pointer-events: none;
}
.card:hover {
    transform: translateY(-4px);
    border-color: rgba(76,201,255,.4);
}
.card .icon {
    font-size: 1.6rem;
    width: 48px; height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(9,72,161,.6), rgba(138,92,255,.4));
    margin-bottom: 16px;
    box-shadow: inset 0 0 0 1px rgba(76,201,255,.3);
}
.card h3 { margin-bottom: 8px; }
.card p { color: var(--text-dim); margin: 0; }

/* ---------- generic content ---------- */

.page-hero {
    padding: 70px 0 30px;
}
.page-hero h1 {
    background: linear-gradient(135deg, #fff 0%, #4cc9ff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.page-hero p.lead {
    font-size: 1.15rem;
    color: var(--text-dim);
    max-width: 700px;
}

.content-section {
    background: linear-gradient(160deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px 32px;
    margin-bottom: 22px;
    box-shadow: var(--shadow);
}
.content-section h2 {
    color: var(--accent);
    font-size: 1.35rem;
    margin-bottom: 12px;
}
.content-section p:last-child { margin-bottom: 0; }

.rules-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.rules-list li {
    padding: 14px 16px 14px 48px;
    background: rgba(76,201,255,.05);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 10px;
    position: relative;
    color: var(--text);
}
.rules-list li::before {
    content: "\2713";
    position: absolute;
    left: 16px; top: 50%;
    transform: translateY(-50%);
    width: 22px; height: 22px;
    background: linear-gradient(135deg, var(--accent), var(--accent-3));
    color: #0a0e1a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: .8rem;
}

/* gear */
.gear-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    margin-bottom: 80px;
}
.gear-card {
    background: linear-gradient(160deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: border-color .2s ease, transform .2s ease;
}
.gear-card:hover { border-color: rgba(76,201,255,.4); transform: translateY(-3px); }
.gear-card h3 {
    color: var(--accent);
    margin-bottom: 14px;
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: .08em;
}
.gear-card ul { list-style: none; padding: 0; margin: 0; }
.gear-card li {
    padding: 8px 0;
    color: var(--text-dim);
    border-bottom: 1px dashed rgba(76,201,255,.1);
    font-size: .95rem;
}
.gear-card li:last-child { border-bottom: 0; }

/* ---------- forms ---------- */

.form-card {
    background: linear-gradient(160deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 36px;
    box-shadow: var(--shadow);
    margin-bottom: 80px;
}
.form-row { margin-bottom: 18px; }
.form-row label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text);
    font-size: .95rem;
}
.form-row input,
.form-row textarea,
.form-row select {
    width: 100%;
    padding: 14px 16px;
    background: rgba(10, 14, 26, .6);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.form-row input:focus,
.form-row textarea:focus,
.form-row select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(76, 201, 255, .15);
}
.form-row textarea { min-height: 140px; resize: vertical; }
.form-row.row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
@media (max-width: 600px) {
    .form-row.row-2 { grid-template-columns: 1fr; }
}

.flash {
    padding: 14px 18px;
    border-radius: 12px;
    margin-bottom: 22px;
    border: 1px solid var(--border);
}
.flash.success {
    background: rgba(0, 255, 163, .08);
    border-color: rgba(0, 255, 163, .35);
    color: var(--accent-3);
}
.flash.error {
    background: rgba(255, 85, 119, .08);
    border-color: rgba(255, 85, 119, .35);
    color: var(--danger);
}

/* ---------- footer ---------- */

.site-footer {
    margin-top: 60px;
    border-top: 1px solid var(--border);
    background: rgba(10, 14, 26, .6);
    padding: 40px 0;
    position: relative;
    z-index: 2;
}
.footer-inner { text-align: center; }
.footer-blurb { color: var(--text-dim); max-width: 600px; margin: 0 auto 16px; }
.footer-social {
    display: flex;
    gap: 18px;
    justify-content: center;
    margin-bottom: 14px;
}
.footer-social a {
    color: var(--text-dim);
    font-weight: 600;
    font-size: .9rem;
}
.footer-copy {
    color: var(--text-dim);
    font-size: .85rem;
    margin: 0;
    opacity: .7;
}

/* ============================================================
   Admin
   ============================================================ */

.admin-body {
    background: var(--bg);
    min-height: 100vh;
}
.admin-wrap {
    max-width: 980px;
    margin: 0 auto;
    padding: 40px 24px 80px;
    position: relative;
    z-index: 2;
}
.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}
.admin-header h1 {
    font-size: 1.6rem;
    margin: 0;
    background: linear-gradient(135deg, #fff, #4cc9ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.admin-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.admin-tabs a {
    padding: 10px 18px;
    border-radius: 10px;
    background: var(--panel);
    border: 1px solid var(--border);
    color: var(--text-dim);
    font-weight: 600;
    font-size: .9rem;
}
.admin-tabs a.active {
    color: var(--text);
    background: linear-gradient(135deg, rgba(9,72,161,.6), rgba(138,92,255,.4));
    border-color: rgba(76,201,255,.4);
}

.admin-section {
    background: linear-gradient(160deg, var(--panel), var(--panel-2));
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
    margin-bottom: 22px;
}
.admin-section h2 {
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--accent);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.admin-login {
    max-width: 420px;
    margin: 100px auto;
    padding: 40px;
    background: linear-gradient(160deg, var(--panel), var(--panel-2));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    position: relative;
    z-index: 2;
}
.admin-login h1 {
    font-size: 1.6rem;
    text-align: center;
    margin-bottom: 24px;
    background: linear-gradient(135deg, #fff, #4cc9ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.admin-login .brand-mark {
    text-align: center;
    margin-bottom: 20px;
}
.admin-login .brand-mark img { height: 56px; margin: 0 auto; }

.btn-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 8px;
}
.btn-sm {
    padding: 9px 16px;
    font-size: .85rem;
    border-radius: 8px;
    background: var(--panel);
    border: 1px solid var(--border);
    color: var(--text);
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.btn-sm:hover { border-color: var(--accent); color: var(--accent); }
.btn-sm.danger:hover { border-color: var(--danger); color: var(--danger); }

.submission {
    background: rgba(10,14,26,.5);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 18px;
    margin-bottom: 14px;
}
.submission .meta {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--text-dim);
    font-size: .85rem;
    margin-bottom: 10px;
}
.submission .meta strong { color: var(--text); }
.submission .body {
    color: var(--text);
    white-space: pre-wrap;
    background: rgba(0,0,0,.25);
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid var(--border);
    font-size: .95rem;
}
.submission .tag {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(76,201,255,.12);
    border: 1px solid rgba(76,201,255,.3);
    color: var(--accent);
    font-size: .75rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-right: 6px;
}
.submission .tag.contact { background: rgba(138,92,255,.12); border-color: rgba(138,92,255,.3); color: #b89cff; }

.repeater-item {
    background: rgba(10,14,26,.4);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
}
.repeater-item .form-row { margin-bottom: 12px; }
.repeater-item .form-row:last-child { margin-bottom: 0; }
.repeater-actions { margin-top: 8px; }

.muted { color: var(--text-dim); font-size: .9rem; }
