:root {
    --theme: #ef4444;
    --pink: #ec4899;
    --ink-900: #000000;
    --ink-800: #111827;
}

* { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
       background: #f7f6fb; color: #1a1a1a; }
a { color: var(--theme); text-decoration: none; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 1rem; }
.site-header { background: #fff; border-bottom: 1px solid #eee; position: sticky; top: 0; z-index: 30; }
.header-row { display: flex; align-items: center; justify-content: space-between; padding: .75rem 1rem; }
.brand { font-size: 1.2rem; color: var(--theme); }
.nav-links { display: flex; gap: 1.25rem; font-size: .9rem; }

.hero { background: linear-gradient(135deg, color-mix(in srgb, var(--theme) 12%, white), white);
        padding: 3rem 1rem; border-radius: 1.5rem; margin: 1.5rem 0; }
.hero h1 { font-size: 2.2rem; margin: 0 0 .5rem; }
.hero p { color: #555; margin: 0; }

.section-title { margin: 2rem 0 1rem; }
.grid-cards { display: grid; gap: 1.25rem;
              grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.event-card { background: #fff; border-radius: 1rem; overflow: hidden;
              box-shadow: 0 1px 3px rgba(0,0,0,.06); transition: transform .2s;
              color: inherit; display: flex; flex-direction: column; }
.event-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,.08); }
.poster { aspect-ratio: 16/10; overflow: hidden; background: #eee; }
.poster img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 1rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.card-body h3 { font-size: 1rem; margin: 0; }
.meta { list-style: none; padding: 0; margin: 0; font-size: .85rem; color: #666; }
.meta li { display: flex; gap: .4rem; align-items: center; margin: .2rem 0; }
.meta i { color: var(--theme); }
.card-foot { margin-top: auto; padding-top: .75rem; border-top: 1px solid #eee;
             display: flex; justify-content: space-between; align-items: center; }
.cta { color: var(--theme); font-weight: 600; font-size: .9rem; }

.event-layout, .checkout-layout { display: grid; gap: 1.5rem; grid-template-columns: 2fr 1fr; }
@media (max-width: 860px) { .event-layout, .checkout-layout { grid-template-columns: 1fr; } }

.card { background: #fff; border-radius: 1rem; padding: 1.25rem;
        box-shadow: 0 1px 3px rgba(0,0,0,.05); margin-bottom: 1rem; }
.card.center { text-align: center; }
.poster-large { width: 100%; border-radius: 1rem; margin-bottom: 1rem; }
.thumb { width: 64px; height: 64px; object-fit: cover; border-radius: .5rem; }
.row { display: flex; gap: 1rem; align-items: center; }

.ticket-row { border: 1px solid #eee; border-radius: .75rem; padding: .75rem;
              margin-bottom: .5rem; display: flex; justify-content: space-between;
              align-items: center; flex-wrap: wrap; gap: .5rem; }
.ticket-info { min-width: 130px; }
.ticket-controls { display: flex; gap: .5rem; align-items: center; }

.qty-stepper { display: inline-flex; border: 1px solid #ddd; border-radius: .5rem; overflow: hidden; }
.qty-btn { background: #fff; border: 0; width: 2rem; cursor: pointer; }
.qty-input { width: 3rem; text-align: center; border: 0; padding: .35rem; font: inherit; }


/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.55rem 0.9rem;
       border: 0; border-radius: 0.5rem; cursor: pointer; font: inherit; font-weight: 600;
       background: #eee; color: #222; transition: opacity .15s; text-decoration: none; }
.btn:hover { opacity: .9; }
.btn-sm { padding: 0.35rem 0.7rem; font-size: 0.85rem; }
.btn-primary { background: var(--theme); color: #fff; }
.btn-soft { background: color-mix(in srgb, var(--theme) 10%, white); color: var(--theme); }
.btn-outline { background: #fff; border: 1px solid #ddd; }
.btn-block { width: 100%; justify-content: center; padding: .8rem; font-size: 1rem; }

/* Alerts */
.alert { padding: .75rem 1rem; border-radius: .6rem; margin-bottom: 1rem; }
.alert-success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.alert-error   { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }


label { display: block; margin-bottom: .75rem; font-size: .9rem; }
label input { display: block; width: 100%; padding: .65rem .8rem; margin-top: .25rem;
              border: 1px solid #ddd; border-radius: .5rem; font: inherit; }
label input:focus { outline: 2px solid color-mix(in srgb, var(--theme) 40%, transparent); border-color: var(--theme); }

.pm-label { font-weight: 600; margin-top: .5rem; }
.pm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin-bottom: 1rem; }
.pm-card input { display: none; }
.pm-inner { padding: .9rem; border: 1px solid #ddd; border-radius: .75rem;
            text-align: center; cursor: pointer; transition: all .15s; }
.pm-card input:checked + .pm-inner {
  border-color: var(--theme);
  background: color-mix(in srgb, var(--theme) 8%, white);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--theme) 20%, transparent);
}

.table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; }
.table th, .table td { padding: .55rem; border-bottom: 1px solid #eee; text-align: left; }
.sum-row { display: flex; justify-content: space-between; margin: .4rem 0; font-size: .9rem; }

.spinner { width: 50px; height: 50px; margin: 0 auto 1rem;
           border: 5px solid #f3f4f6; border-top-color: var(--theme);
           border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.hidden { display: none !important; }
.md\:hidden { display: block; } /* Mobile menu logic uses CSS classes */
@media (min-width: 768px) {
    .md\:flex { display: flex !important; }
    .md\:hidden { display: none !important; }
}

.muted { color: #666; }
.small { font-size: .8rem; }
.site-footer { 
    border-top: 1px solid #eee; 
    padding: 1.5rem 0;
    background: #fff; 
    text-align: center; 
    color: #888; 
    font-size: .85rem; 
    
    /* Centering magic */
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
}

.admin-header { display: flex; justify-content: space-between; align-items: center;
                margin: 1.5rem 0 1rem; gap: 1rem; flex-wrap: wrap; }
.admin-table { background: #fff; border-radius: 1rem; overflow: hidden;
               box-shadow: 0 1px 3px rgba(0,0,0,.05); }
.admin-table th, .admin-table td { padding: .65rem .8rem; vertical-align: top; }
.admin-table tr:hover { background: #fafafa; }
.thumb-sm { width: 56px; height: 40px; object-fit: cover; border-radius: .4rem; }
.row-actions { display: flex; gap: .35rem; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1rem; }
.tier-prices { border: 1px solid #eee; border-radius: .75rem; padding: 1rem; margin: 1rem 0; }
.tier-prices legend { font-weight: 600; padding: 0 .4rem; }
.form-actions { display: flex; gap: .5rem; margin-top: 1rem; }
.admin-form textarea { display: block; width: 100%; padding: .65rem .8rem; margin-top: .25rem;
                       border: 1px solid #ddd; border-radius: .5rem; font: inherit; }