/* Skyyber Entertainment - Phase 1 temporary visual system.
   Restrained dark entertainment-industry palette. Replace tokens when real
   brand assets exist; nothing below hard-codes a brand image. */

:root {
  --bg:        #0B0D12;
  --surface:   #141821;
  --surface-2: #1B2029;
  --border:    #272E3B;
  --border-lt: #333C4C;
  --text:      #E9ECF3;
  --muted:     #98A1B3;
  --faint:     #6B7488;
  --accent:    #7C5CFF;
  --accent-dk: #6547E8;
  --accent-sf: rgba(124,92,255,.14);
  --ok:        #2FBF71;
  --ok-sf:     rgba(47,191,113,.14);
  --warn:      #E8A33D;
  --warn-sf:   rgba(232,163,61,.14);
  --bad:       #E05561;
  --bad-sf:    rgba(224,85,97,.14);
  --radius:    12px;
  --radius-sm: 8px;
  --tap:       44px;
  --shadow:    0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.24);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--font); font-size: 16px; line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0 0 .5rem; line-height: 1.25; letter-spacing: -.02em; font-weight: 650; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.15rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 .75rem; }
hr { border: 0; border-top: 1px solid var(--border); margin: 1.25rem 0; }

/* ---------- Layout ---------- */
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 1rem 5rem; }
.topbar {
  position: sticky; top: 0; z-index: 40; background: rgba(11,13,18,.92);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.topbar-in {
  max-width: 1080px; margin: 0 auto; padding: .6rem 1rem;
  display: flex; align-items: center; gap: .75rem;
}
.brand { display: flex; align-items: center; gap: .55rem; font-weight: 700; letter-spacing: -.02em; color: var(--text); }
.brand:hover { text-decoration: none; }
/* The logo artwork ships on a solid black field. `screen` blending makes that
   black read as transparent against the dark UI, so no alpha editing is needed.
   Safe because this interface is dark-only. */
.brand-mark {
  height: 30px; width: auto; flex: 0 0 auto; display: block;
  mix-blend-mode: screen;
}
.auth-logo {
  display: block; width: 168px; max-width: 55%; height: auto;
  margin: 0 auto .45rem; mix-blend-mode: screen;
}
.brand-sub { color: var(--faint); font-weight: 500; font-size: .78rem; letter-spacing: .04em; text-transform: uppercase; }
.topbar-spacer { margin-left: auto; }

nav.mainnav {
  border-bottom: 1px solid var(--border); background: var(--bg);
  overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
nav.mainnav::-webkit-scrollbar { display: none; }
nav.mainnav ul {
  display: flex; gap: .25rem; list-style: none; margin: 0 auto; padding: 0 .6rem;
  max-width: 1080px;
}
nav.mainnav a {
  display: block; padding: .7rem .7rem; color: var(--muted); font-size: .9rem;
  font-weight: 550; white-space: nowrap; border-bottom: 2px solid transparent;
  min-height: var(--tap); line-height: 1.7;
}
nav.mainnav a:hover { color: var(--text); text-decoration: none; }
nav.mainnav a.on { color: var(--text); border-bottom-color: var(--accent); }

.page-head {
  display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-start;
  justify-content: space-between; margin: 1.25rem 0 1rem;
}
.page-head p { color: var(--muted); font-size: .9rem; margin: .15rem 0 0; }

/* ---------- Cards & grids ---------- */
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1rem; margin-bottom: .85rem;
}
.card-tight { padding: .8rem; }
.card h2, .card h3 { margin-bottom: .35rem; }
.grid { display: grid; gap: .85rem; grid-template-columns: 1fr; }
/* Stat rows stay two-up on phones rather than becoming a tall stack. */
@media (max-width: 719px) { .grid-4, .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 720px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .85rem; }
.stat .n { font-size: 1.75rem; font-weight: 700; letter-spacing: -.03em; display: block; }
.stat .l { color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; }
.stat.alert .n { color: var(--warn); }

/* ---------- Opportunity cards ---------- */
.opp { display: block; color: inherit; }
.opp:hover { text-decoration: none; border-color: var(--border-lt); }
.opp-title { font-size: 1.05rem; font-weight: 650; letter-spacing: -.01em; }
.opp-meta { display: flex; flex-wrap: wrap; gap: .35rem .9rem; color: var(--muted); font-size: .875rem; margin-top: .4rem; }
.opp-meta span { display: inline-flex; align-items: center; gap: .3rem; }
.opp-pay { color: var(--ok); font-weight: 600; }
.deadline { color: var(--warn); font-size: .82rem; }
.deadline.past { color: var(--bad); }

/* ---------- Badges ---------- */
.badge {
  display: inline-block; padding: .18rem .5rem; border-radius: 100px;
  font-size: .72rem; font-weight: 650; letter-spacing: .03em; text-transform: uppercase;
  border: 1px solid var(--border-lt); color: var(--muted); background: var(--surface-2);
  white-space: nowrap;
}
.badge.ok      { color: var(--ok);     background: var(--ok-sf);     border-color: transparent; }
.badge.warn    { color: var(--warn);   background: var(--warn-sf);   border-color: transparent; }
.badge.bad     { color: var(--bad);    background: var(--bad-sf);    border-color: transparent; }
.badge.accent  { color: var(--accent); background: var(--accent-sf); border-color: transparent; }
.badge-row { display: flex; flex-wrap: wrap; gap: .3rem; }
.tag {
  display: inline-block; padding: .15rem .45rem; border-radius: 5px; font-size: .74rem;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--muted);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  min-height: var(--tap); padding: .6rem 1rem; border-radius: var(--radius-sm);
  border: 1px solid var(--border-lt); background: var(--surface-2); color: var(--text);
  font: inherit; font-size: .92rem; font-weight: 600; cursor: pointer; text-align: center;
}
.btn:hover { text-decoration: none; border-color: var(--faint); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dk); border-color: var(--accent-dk); }
.btn-ok   { background: var(--ok);  border-color: var(--ok);  color: #06240f; }
.btn-bad  { background: transparent; border-color: var(--bad); color: var(--bad); }
.btn-ghost { background: transparent; }
.btn-sm { min-height: 36px; padding: .3rem .65rem; font-size: .82rem; }
.btn-block { width: 100%; }
.btn:disabled, .btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: .5rem; }
.btn-row form { margin: 0; }

/* Response actions: full width and thumb-friendly on phones. */
.respond { display: grid; gap: .55rem; grid-template-columns: 1fr; }
.respond .btn { min-height: 52px; font-size: 1rem; }
@media (min-width: 620px) { .respond { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Forms ---------- */
form { margin: 0 0 .5rem; }
.field { margin-bottom: .85rem; }
.field label, .lbl {
  display: block; font-size: .82rem; font-weight: 600; color: var(--muted);
  margin-bottom: .3rem; letter-spacing: .01em;
}
.field .hint { font-size: .78rem; color: var(--faint); margin-top: .25rem; }
input[type=text], input[type=email], input[type=password], input[type=tel],
input[type=date], input[type=time], input[type=number], input[type=url], select, textarea {
  width: 100%; min-height: var(--tap); padding: .55rem .65rem; font: inherit; font-size: 16px;
  color: var(--text); background: var(--surface-2); border: 1px solid var(--border-lt);
  border-radius: var(--radius-sm); appearance: none;
}
textarea { min-height: 90px; resize: vertical; line-height: 1.5; }
select { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
                           linear-gradient(135deg, var(--muted) 50%, transparent 50%);
         background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
         background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 2rem; }
input:focus, select:focus, textarea:focus, .btn:focus-visible, a:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent);
}
.check { display: flex; align-items: flex-start; gap: .55rem; padding: .5rem 0; min-height: var(--tap); }
.check input[type=checkbox], .check input[type=radio] { width: 20px; height: 20px; margin-top: .15rem; flex: 0 0 20px; accent-color: var(--accent); }
.check label { margin: 0; font-size: .92rem; color: var(--text); font-weight: 500; }
.check .hint { color: var(--faint); font-size: .8rem; display: block; margin-top: .15rem; font-weight: 400; }
.form-grid { display: grid; gap: 0 .85rem; grid-template-columns: 1fr; }
@media (min-width: 620px) { .form-grid.two { grid-template-columns: 1fr 1fr; } }
fieldset { border: 1px solid var(--border); border-radius: var(--radius); padding: .85rem; margin: 0 0 .85rem; }
legend { padding: 0 .4rem; font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); font-weight: 700; }
.filters { display: grid; gap: .5rem; grid-template-columns: 1fr; }
@media (min-width: 620px) { .filters { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .filters { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Notices ---------- */
.notice {
  padding: .7rem .85rem; border-radius: var(--radius-sm); margin-bottom: .85rem;
  font-size: .9rem; border: 1px solid transparent;
}
.notice.info { background: var(--accent-sf); color: #C3B6FF; border-color: rgba(124,92,255,.3); }
.notice.good { background: var(--ok-sf);     color: #86E3AE; border-color: rgba(47,191,113,.3); }
.notice.err  { background: var(--bad-sf);    color: #F09AA2; border-color: rgba(224,85,97,.35); }
.notice.warn { background: var(--warn-sf);   color: #F0C687; border-color: rgba(232,163,61,.3); }
.notice ul { margin: .35rem 0 0; padding-left: 1.1rem; }

.empty {
  text-align: center; padding: 2rem 1rem; color: var(--muted);
  border: 1px dashed var(--border-lt); border-radius: var(--radius); background: var(--surface);
}
.empty .big { font-size: 1.6rem; display: block; margin-bottom: .4rem; opacity: .6; }
.empty p { margin: 0 0 .75rem; font-size: .92rem; }

/* ---------- Tables / lists ---------- */
.tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; padding: .6rem .5rem; border-bottom: 1px solid var(--border); vertical-align: top; }
th { color: var(--faint); font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; font-weight: 700; }
tr:last-child td { border-bottom: 0; }

@media (max-width: 719px) {
  table.stacked thead { position: absolute; width: 1px; height: 1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  table.stacked tr {
    display: block; border: 1px solid var(--border); border-radius: var(--radius);
    padding: .7rem; margin-bottom: .6rem; background: var(--surface-2);
  }
  table.stacked td { display: block; border: 0; padding: .2rem 0; text-align: left; }
  table.stacked td[data-label="Note"]:not(:empty)::before,
  table.stacked td[data-label="Contact"]::before {
    content: attr(data-label); display: block; color: var(--faint);
    font-size: .7rem; text-transform: uppercase; letter-spacing: .05em;
    font-weight: 700; margin-top: .4rem;
  }
  table.stacked td[data-label="Actions"] .btn-row { justify-content: flex-start; }
  table.stacked td[data-label="Actions"] { margin-top: .5rem; }
  table.stacked td[data-label="Actions"] .btn { flex: 1 1 auto; }
  table.stacked td:empty { display: none; }
}
/* Keep a placeholder dash in the wide table so columns still read as a grid. */
@media (min-width: 720px) {
  table.stacked td[data-label="Note"]:empty::after { content: "—"; color: var(--faint); }
}

.rowlist { list-style: none; margin: 0; padding: 0; }
.rowlist li {
  display: flex; flex-wrap: wrap; gap: .5rem; align-items: center;
  padding: .7rem 0; border-bottom: 1px solid var(--border);
}
.rowlist li:last-child { border-bottom: 0; }
.rowlist .grow { flex: 1 1 200px; min-width: 0; }
.rowlist .nm { font-weight: 600; }
.rowlist .sub { color: var(--muted); font-size: .82rem; }

.person { display: flex; align-items: center; gap: .6rem; min-width: 0; }
.avatar {
  width: 36px; height: 36px; border-radius: 50%; flex: 0 0 36px; object-fit: cover;
  background: var(--surface-2); border: 1px solid var(--border-lt);
  display: grid; place-items: center; font-size: .8rem; font-weight: 700; color: var(--muted);
}

.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: .84rem; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .82rem; word-break: break-all; }
.nowrap { white-space: nowrap; }
.mt { margin-top: 1rem; }
.mb0 { margin-bottom: 0; }
.right { text-align: right; }
.copybox {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: .6rem; white-space: pre-wrap; word-break: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .8rem; color: var(--muted);
  max-height: 240px; overflow: auto;
}
.footer { color: var(--faint); font-size: .78rem; text-align: center; padding: 2rem 1rem 1rem; }

/* ---------- Auth screens ---------- */
.auth { max-width: 400px; margin: 3rem auto; padding: 0 1rem; }
.auth .card { padding: 1.5rem; }
.auth-brand { text-align: center; margin-bottom: 1.5rem; }
.auth-brand h1 { font-size: 1.3rem; margin: 0 0 .15rem; }
.auth-brand p { color: var(--muted); font-size: .88rem; margin: 0; }

@media print { .topbar, nav.mainnav, .btn { display: none; } body { background: #fff; color: #000; } }
