/* ─── events.fadafad.com · minimal design system ───────────────────────── */
:root {
    --bg: #0f1220;
    --bg-2: #161a2e;
    --panel: #ffffff;
    --ink: #1a1c2c;
    --ink-2: #4a5068;
    --muted: #8087a0;
    --brand: #4f46e5;
    --brand-2: #7c3aed;
    --accent: #22c55e;
    --danger: #ef4444;
    --border: #e5e7ef;
    --shadow: 0 2px 12px rgba(20, 24, 60, 0.06);
    --radius: 12px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font: 15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Ubuntu, sans-serif;
    color: var(--ink);
    background: #f6f7fb;
    min-height: 100vh;
    display: flex; flex-direction: column;
}
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0 0 .5em; line-height: 1.25; }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.25rem; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; width: 100%; }
.page { flex: 1; padding: 32px 20px; }

/* header/footer */
.site-header {
    background: var(--panel);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { font-weight: 700; font-size: 18px; color: var(--ink); }
.brand-dot { color: var(--brand); }
.nav { display: flex; align-items: center; gap: 16px; }
.nav a { color: var(--ink-2); font-weight: 500; }
.nav .who { color: var(--muted); font-size: 13px; }
.site-footer {
    padding: 24px 0;
    border-top: 1px solid var(--border);
    background: var(--panel);
    color: var(--muted);
    font-size: 13px;
}
.site-footer .wrap { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* admin styling */
body.is-admin { background: #f0f2fb; }
body.is-admin .site-header { background: linear-gradient(135deg, var(--brand), var(--brand-2)); }
body.is-admin .site-header .brand,
body.is-admin .site-header .nav a,
body.is-admin .site-header .nav .who { color: #fff; }
body.is-admin .site-header .brand-dot { color: #ffd166; }

/* buttons */
.btn {
    display: inline-block;
    background: var(--brand);
    color: #fff !important;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    text-decoration: none !important;
}
.btn:hover { background: var(--brand-2); }
.btn-sm { padding: 6px 12px; font-size: 13px; }
button.linklike {
    background: none; border: none; padding: 0; color: var(--brand);
    cursor: pointer; font: inherit; text-decoration: underline;
}

form.inline { display: inline; }
form.stack { display: flex; flex-direction: column; gap: 12px; max-width: 520px; }
form.stack label { display: flex; flex-direction: column; gap: 4px; font-weight: 500; color: var(--ink-2); }
form.stack input, form.stack select, form.stack textarea {
    padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px;
    font: inherit; background: #fff;
}
form.stack .row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
form.stack .check { flex-direction: row; align-items: center; gap: 8px; font-weight: 400; }
.card-form { background: var(--panel); padding: 20px; border-radius: var(--radius); box-shadow: var(--shadow); margin: 20px 0; max-width: 640px; }

/* hero */
.hero {
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    color: #fff;
    border-radius: var(--radius);
    padding: 48px 32px;
    margin-bottom: 32px;
    text-align: center;
}
.hero h1 { color: #fff; font-size: 2rem; margin-bottom: 8px; }
.hero-sub { opacity: .9; margin: 0 0 24px; }
.hero-search { display: flex; gap: 8px; max-width: 520px; margin: 0 auto; }
.hero-search input {
    flex: 1; padding: 12px 14px; border-radius: 8px; border: none; font: inherit;
}
.hero-search .btn { background: #fff; color: var(--brand) !important; }
.hero-search .btn:hover { background: #eef2ff; }

/* card grid */
.section { margin-bottom: 40px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 16px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.card {
    display: block;
    background: var(--panel);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    color: var(--ink) !important;
    text-decoration: none !important;
    transition: transform .15s, box-shadow .15s;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(20,24,60,.12); }
.card-banner {
    background: linear-gradient(135deg, #a5b4fc, #c084fc) center/cover no-repeat #a5b4fc;
    height: 140px;
}
.card-body { padding: 14px 16px; }
.card-title { font-weight: 600; margin-bottom: 4px; }
.card-meta { font-size: 13px; color: var(--ink-2); }
.card-price { margin-top: 8px; color: var(--brand); font-weight: 600; }

/* event detail */
.event-banner { height: 260px; border-radius: var(--radius); background-size: cover; background-position: center; margin-bottom: 20px; }
.event-meta { color: var(--ink-2); margin-bottom: 20px; }
.event-desc { margin-bottom: 24px; white-space: pre-wrap; }

/* filters */
.filters { display: flex; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; align-items: center; }
.filters input { padding: 10px 12px; border-radius: 8px; border: 1px solid var(--border); font: inherit; }

/* table */
.table { width: 100%; border-collapse: collapse; background: var(--panel); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.table th, .table td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--border); font-size: 14px; }
.table th { background: #fafbff; color: var(--ink-2); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.table tr:last-child td { border-bottom: none; }

/* auth card */
.auth-card { max-width: 400px; margin: 40px auto; padding: 32px; background: var(--panel); border-radius: var(--radius); box-shadow: var(--shadow); }
.auth-card h1 { text-align: center; margin-bottom: 20px; }

/* utilities */
.muted { color: var(--muted); }
.small { font-size: 12px; }
.empty { padding: 32px; text-align: center; color: var(--muted); background: var(--panel); border-radius: var(--radius); }
.alert { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
.alert.error { background: #fee2e2; color: #991b1b; }

/* badges */
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; background: #eef2ff; color: var(--brand); }
.badge.published, .badge.paid { background: #dcfce7; color: #166534; }
.badge.draft { background: #fef3c7; color: #92400e; }
.badge.cancelled, .badge.refunded { background: #fee2e2; color: #991b1b; }
.badge.completed { background: #e0e7ff; color: #3730a3; }
.badge.pending { background: #fef3c7; color: #92400e; }

/* stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; margin-bottom: 32px; }
.stat { background: var(--panel); padding: 20px; border-radius: var(--radius); box-shadow: var(--shadow); text-align: center; }
.stat-n { font-size: 28px; font-weight: 700; color: var(--brand); }
.stat-l { color: var(--muted); font-size: 13px; margin-top: 4px; }

/* tickets on order page */
.tickets { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; margin-bottom: 24px; }
.ticket {
    display: flex; align-items: center; gap: 16px;
    background: var(--panel); border-radius: var(--radius); padding: 16px;
    box-shadow: var(--shadow);
}
.ticket-left { flex: 1; }
.ticket-type { font-weight: 600; margin-bottom: 4px; }
.ticket-code { font-size: 13px; color: var(--ink-2); }
.ticket-qr { width: 96px; height: 96px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
