/* =============================================================================
   BLOW Beach House — Dashboard
   Huisstijl: burnt orange + cream, Nord caps + Assistant body
   ============================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@400;500;700&family=Assistant:wght@200;300;400;600&family=Caveat:wght@400;600&family=Bungee&display=swap');

:root {
  /* Huisstijl hoofdkleuren */
  --orange:       #C66A1F;
  --orange-dark:  #A85812;
  --yellow:       #F5C63F;
  --black:        #000000;
  --charcoal:     #1A1A1A;
  --grey-light:   #D9D8D7;
  --cream:        #F4EFE2;
  --sand:         #DDD5C5;
  --blue-grey:    #B3C4C4;
  --purple:       #7B77C7;
  --petrol:       #2D6687;
  --electric:     #1E3DE5;

  /* Derived */
  --bg:           var(--cream);
  --bg-card:      #FFFFFF;
  --bg-card-alt:  var(--sand);
  --text:         var(--charcoal);
  --text-dim:     #666;
  --border:       var(--grey-light);

  /* Fonts */
  --font-display: "Oswald", "Bebas Neue", sans-serif;
  --font-body:    "Assistant", sans-serif;
  --font-hand:    "Caveat", cursive;
  --font-poster:  "Bungee", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.5;
  min-height: 100vh;
  padding-bottom: 60px;
}

a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--orange-dark); }

/* ---------- Header ---------- */
.header {
  background: var(--orange);
  color: var(--cream);
  padding: 20px 32px;
  display: flex;
  align-items: center;
  gap: 18px;
  border-bottom: 4px solid var(--charcoal);
}
.header .logo {
  width: 52px; height: 52px;
  border: 2.5px solid var(--cream);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 2px;
  flex-shrink: 0;
}
.header h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 24px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.header .subtitle {
  font-family: var(--font-hand);
  font-size: 18px;
  color: var(--cream);
  opacity: 0.85;
  margin-top: -2px;
}
.header .weather-badge {
  margin-left: auto;
  background: var(--cream);
  color: var(--charcoal);
  padding: 8px 18px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 1px;
  display: flex; align-items: center; gap: 8px;
}

/* ---------- Tabs (hoofdmenu) ---------- */
.tabs {
  display: flex;
  gap: 4px;
  padding: 0 32px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
}
.tab {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  padding: 16px 22px 14px;
  color: var(--text-dim);
  border-bottom: 3px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s, border-color 0.15s;
  white-space: nowrap;
  text-decoration: none;
}
.tab:hover { color: var(--charcoal); }
.tab.active {
  color: var(--orange);
  border-bottom-color: var(--orange);
}
@media (max-width: 600px) {
  .tabs { padding: 0 16px; }
  .tab { padding: 14px 14px 12px; font-size: 13px; letter-spacing: 1.5px; }
}

/* ---------- Sectie koppen ---------- */
.section {
  padding: 28px 32px 0;
}
.section-head {
  display: flex; align-items: baseline; gap: 18px;
  margin-bottom: 6px;
}
.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
}
.section-sub {
  font-family: var(--font-hand);
  font-size: 18px;
  color: var(--petrol);
}
.brush {
  display: block;
  width: 120px; height: 4px;
  background: var(--electric);
  border-radius: 2px;
  transform: skewX(-10deg);
  margin: 2px 0 22px;
  box-shadow: 2px 2px 0 rgba(30,61,229,0.25);
}

/* ---------- Bestel-cards grid ---------- */
.orders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 22px;
}
.order-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  display: flex; flex-direction: column; gap: 10px;
  transition: transform .15s, box-shadow .15s;
}
.order-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}
.order-card.holiday {
  background: var(--yellow);
  border-color: var(--orange);
}
.order-card.weekend {
  border-left: 4px solid var(--orange);
}
.order-head {
  display: flex; justify-content: space-between; align-items: baseline;
}
.order-day {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.order-date {
  font-size: 13px;
  color: var(--text-dim);
}
.order-weer {
  display: flex; align-items: center; gap: 10px;
  font-size: 14px;
  color: var(--text-dim);
}
.order-weer .big-icon { font-size: 22px; }
.order-count {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--orange);
  font-size: 42px;
  line-height: 1;
  margin-top: 2px;
}
.order-count-unit {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 13px;
  color: var(--text-dim);
  margin-top: -4px;
}
.order-flags {
  display: flex; flex-wrap: wrap; gap: 4px;
}
.pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-family: var(--font-display);
}
.pill-nl    { background: var(--orange);    color: var(--cream); }
.pill-nrw   { background: var(--purple);    color: #fff; }
.pill-school{ background: var(--blue-grey); color: var(--charcoal); }
.pill-we    { background: var(--sand);      color: var(--charcoal); }

/* ---------- Totaal banner ---------- */
.totaal-banner {
  background: var(--charcoal);
  color: var(--cream);
  border-radius: 14px;
  padding: 22px 28px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 16px;
}
.totaal-label {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--grey-light);
}
.totaal-value {
  font-family: var(--font-poster);
  font-size: 48px;
  color: var(--yellow);
  line-height: 1;
}
.totaal-note {
  font-family: var(--font-hand);
  font-size: 16px;
  color: var(--grey-light);
}

/* ---------- Historie chart ---------- */
.chart-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 22px;
  margin-bottom: 22px;
}
.chart-card canvas {
  width: 100% !important;
  max-height: 340px;
}

/* ---------- KPI-row ---------- */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}
.kpi {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 14px 18px;
}
.kpi-lbl {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-dim);
}
.kpi-val {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 28px;
  color: var(--orange);
  margin-top: 4px;
  line-height: 1.1;
}
.kpi-sub {
  font-size: 11px;
  color: var(--text-dim);
}

/* ---------- Footer ---------- */
.footer {
  padding: 40px 32px 0;
  text-align: center;
  font-size: 11px;
  color: var(--text-dim);
  font-family: var(--font-hand);
}
.footer .big { font-size: 15px; color: var(--text); }

/* ---------- Status badge ---------- */
.status {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  font-family: var(--font-display);
  letter-spacing: 1px;
  text-transform: uppercase;
}
.status-ok    { background: #c8e6c9; color: #2e7d32; }
.status-warn  { background: var(--yellow); color: var(--charcoal); }
.status-error { background: #ffcdd2; color: #c62828; }

/* ---------- Loading state ---------- */
.loading {
  text-align: center;
  padding: 60px 20px;
  font-family: var(--font-hand);
  font-size: 20px;
  color: var(--text-dim);
}

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .header { padding: 14px 18px; gap: 12px; }
  .header h1 { font-size: 18px; }
  .header .weather-badge { padding: 6px 12px; font-size: 12px; }
  .section { padding: 20px 18px 0; }
  .section-title { font-size: 18px; }
  .totaal-value { font-size: 36px; }
  .order-count { font-size: 36px; }
}
