:root{
  --bg:#05070c;
  --accent:#3aa8ff;
  --text:#ffffff;
}

*{box-sizing:border-box;margin:0;padding:0;font-family:Segoe UI, Arial;}
body{background:var(--bg); color:var(--text); min-height:100svh;}
a{color:inherit; text-decoration:none}

.wrap{width:92%; max-width:1050px; margin:0 auto; padding:26px 0;}
.topbar{
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  padding:14px 16px; border-radius:18px;
  background:rgba(255,255,255,.03);
  border:1px solid rgba(255,255,255,.10);
}
.brand{display:flex; align-items:center; gap:10px;}
.brand img{height:38px;}
.badge{
  font-size:12px; letter-spacing:.8px;
  padding:6px 10px; border-radius:999px;
  border:1px solid rgba(255,255,255,.14);
  background:rgba(255,255,255,.02);
  color:rgba(255,255,255,.78);
}

.grid{
  margin-top:16px;
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:16px;
}
@media (max-width: 900px){ .grid{grid-template-columns:1fr;} }

.card{
  background:rgba(255,255,255,.03);
  border:1px solid rgba(255,255,255,.10);
  border-radius:18px;
  padding:18px;
}
.card h2{font-size:18px; letter-spacing:.2px;}
.card p{margin-top:8px; color:rgba(255,255,255,.70); line-height:1.6; font-size:14px;}

.field{margin-top:12px; display:grid; gap:8px;}
label{font-size:12px; color:rgba(255,255,255,.72); letter-spacing:.6px;}
input, select, textarea{
  background:rgba(255,255,255,.03);
  border:1px solid rgba(255,255,255,.10);
  border-radius:14px;
  padding:12px 14px;
  color:#fff;
  outline:none;
}

/*
  Windows/Chrome native <select> dropdown: option'lar select'in `color` değerini miras alır.
  Koyu temada `color:#fff` olduğu için açılan listede yazılar beyaz kalıp okunmuyor.
  Bu yüzden dropdown içindeki option'ları açık zemin + koyu yazı olarak sabitliyoruz.
*/
select option,
select optgroup{
  background:#fff;
  color:#111;
}

/* Seçili option okunaklı kalsın */
select option:checked{
  background:#e9eefc;
  color:#111;
}
textarea{resize:vertical; min-height:120px;}
input:focus, select:focus, textarea:focus{
  border-color: rgba(58,168,255,.35);
  box-shadow:0 0 0 4px rgba(58,168,255,.10);
}

.btn{
  display:inline-block;
  margin-top:14px;
  padding:12px 18px;
  border-radius:14px;
  background:linear-gradient(135deg,#3aa8ff,#7c5cff);
  color:#08101f;
  font-weight:800;
  border:none;
  cursor:pointer;
}
.btn:active{transform:translateY(1px);}
.btn.secondary{
  background:transparent;
  color:#fff;
  border:1px solid rgba(255,255,255,.14);
}

.table{
  width:100%;
  border-collapse:separate;
  border-spacing:0 10px;
  margin-top:10px;
}
.row{
  background:rgba(255,255,255,.02);
  border:1px solid rgba(255,255,255,.08);
  border-radius:14px;
}
.table th{
  text-align:left;
  font-size:12px;
  color:rgba(255,255,255,.65);
  font-weight:600;
  padding:8px 10px;
}
.table td{
  padding:12px 10px;
  font-size:14px;
  color:rgba(255,255,255,.82);
}
.pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-size:12px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.14);
  background:rgba(255,255,255,.02);
  color:rgba(255,255,255,.78);
}
.dot{
  width:8px; height:8px; border-radius:999px;
  background:rgba(255,255,255,.35);
}
.pill.s1 .dot{background:#3aa8ff;}
.pill.s2 .dot{background:#7c5cff;}
.pill.s3 .dot{background:#f0b429;}
.pill.s4 .dot{background:#22c55e;}

.note{
  margin-top:10px;
  font-size:12px;
  color:rgba(255,255,255,.58);
  line-height:1.6;
}
.err{
  margin-top:10px;
  padding:10px 12px;
  border-radius:14px;
  background:rgba(255,80,80,.10);
  border:1px solid rgba(255,80,80,.25);
  color:rgba(255,255,255,.86);
  display:none;
}
.err.show{display:block;}

/* =======================
   ADMIN CORE (Level 2)
   ======================= */
body.admin-core{
  background:
    radial-gradient(900px 320px at 20% 20%, rgba(58,168,255,.14), transparent 60%),
    radial-gradient(900px 320px at 80% 70%, rgba(124,92,255,.12), transparent 60%),
    linear-gradient(180deg, #05070c, #04060a);
}

body.admin-core .topbar{
  border-color: rgba(58,168,255,.18);
  box-shadow: 0 18px 55px rgba(58,168,255,.10);
  position: relative;
  overflow:hidden;
}

body.admin-core .topbar::before{
  content:"";
  position:absolute;
  inset:-60%;
  background: radial-gradient(circle, rgba(58,168,255,.16), transparent 55%);
  opacity:.55;
  pointer-events:none;
}

body.admin-core .badge{
  border-color: rgba(58,168,255,.25);
  background: rgba(58,168,255,.08);
  color: rgba(255,255,255,.88);
  text-shadow: 0 0 18px rgba(58,168,255,.25);
}

body.admin-core .card{
  border-color: rgba(255,255,255,.10);
  box-shadow: 0 24px 80px rgba(0,0,0,.35);
}

body.admin-core .btn.secondary{
  border-color: rgba(58,168,255,.22);
}

body.admin-core .pill{
  border-color: rgba(58,168,255,.20);
}

/* “System Activated” toast */
.core-toast{
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%) translateY(-14px);
  opacity: 0;
  pointer-events:none;
  z-index: 2000;

  display:flex;
  align-items:center;
  gap:10px;

  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(58,168,255,.28);
  background: rgba(5,7,12,.82);
  backdrop-filter: blur(14px);
  box-shadow: 0 22px 70px rgba(58,168,255,.14);
}

.core-toast .core-dot{
  width:10px; height:10px; border-radius:999px;
  background: rgba(58,168,255,1);
  box-shadow: 0 0 22px rgba(58,168,255,.55);
}

.core-toast strong{
  font-size: 12px;
  letter-spacing: .9px;
}

.core-toast span{
  font-size: 12px;
  color: rgba(255,255,255,.65);
  margin-left: 6px;
}

.core-toast.is-show{
  animation: coreInOut 2.4s ease forwards;
}

@keyframes coreInOut{
  0%   { opacity:0; transform:translateX(-50%) translateY(-14px); }
  18%  { opacity:1; transform:translateX(-50%) translateY(0); }
  80%  { opacity:1; transform:translateX(-50%) translateY(0); }
  100% { opacity:0; transform:translateX(-50%) translateY(-14px); }
}

/* ===== Mini Buttons (Portal) ===== */
.btn-mini{
  padding:8px 10px;
  border-radius:10px;
  border:1px solid rgba(255,255,255,.14);
  background:rgba(255,255,255,.04);
  color:#fff;
  cursor:pointer;
  font-size:12px;
  letter-spacing:.3px;
  transition:.2s;
}

.btn-mini:hover{
  border-color:rgba(58,168,255,.25);
  box-shadow:0 10px 22px rgba(58,168,255,.10);
  transform:translateY(-1px);
}

.btn-mini.danger{
  border-color:rgba(255,80,80,.35);
  background:rgba(255,80,80,.08);
}

.btn-mini.danger:hover{
  box-shadow:0 10px 22px rgba(255,80,80,.10);
}

/* ===== Cancelled status pill ===== */
.pill.s0{
  border-color:rgba(255,80,80,.35);
  background:rgba(255,80,80,.10);
}
.pill.s0 .dot{
  background:rgba(255,80,80,.9);
}


/* ====== Responsive / Table Fixes (2026-02-13) ====== */
.table-wrap{width:100%; overflow-x:auto; -webkit-overflow-scrolling:touch;}
.table{min-width:780px;}
.table th,.table td{padding:10px 10px; font-size:13px; white-space:nowrap;}
.table td{color:rgba(255,255,255,.86);}

.admin-core .wrap{max-width:1320px;}
.admin-core .grid{grid-template-columns:1fr;}
.admin-core .table{min-width:1200px;}
.admin-core .card{overflow:hidden;}
.admin-core .card .table-wrap{border:1px solid rgba(255,255,255,.06); border-radius:14px;}
/* Long note cells wrap nicely when needed */
td.wrap, th.wrap{white-space:normal; min-width:220px;}
