/*
 * FoodApp 2025 theme
 * - Soft gradient background
 * - Solid light navbar (E5E7EB)
 * - Rounded, elevated cards
 * - Pill buttons & search
 */

/* Brand & design tokens */
:root {
  --primary-color: #262F8D;
  --primary-soft: #262F8D;
  --primary-soft-alt: #4B57D0;
  /*--primary-color: #262F8D;
  --primary-soft: #4B57D0;
  --primary-soft-alt: #7B83FF;
  */
  --accent-color: #F4B266;

  --bg-main: #E8DED9;
  --bg-gradient-start: #F9F5FF;
  --bg-gradient-mid: #E4E8FF;

  --surface-color: #FFFFFF;
  --radius-lg: 18px;
  --radius-pill: 999px;

  --text-main: #0F172A;
  --text-muted: #6B7280;
}

/* Global layout */
body {
  min-height: 100vh;
  margin: 0;
  background: var(--bg-main);
  color: var(--text-main);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
}

/* Container a bit tighter voor web-app feeling */
main.container {
  max-width: 1080px;
}

/* NAVBAR – solid light (E5E7EB), geen glass */
.navbar {
  /*position: sticky;
  top: 0;*/
  z-index: 1030;
  background-color: var(--primary-soft) !important;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.06);
  border-bottom: 1px solid rgba(15, 23, 42, 0.03);
}

.navbar.bg-light {
  background-color: var(--primary-soft) !important;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.06);
}

.navbar-brand {
  font-weight: 650;
  letter-spacing: -0.04em;
  color: #ffffff !important;
  font-size: 1.2rem;
}

.navbar-brand::before {
  content: "🍽️ ";
  font-size: 1rem;
  opacity: 0.9;
}

/* Brand block in navbar */
.app-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.1;
}

/* Hoofdtitel: kort, bold, strak */
.app-brand-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: #ffffff;
}

/* Slogan: klein, subtiel, meer “badge”-feeling */
.app-brand-subtitle {
  margin-top: 0.18rem;
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(255, 255, 255, 0.78);
}

/* Emoji iets netter positioneren bij de nieuwe structuur */
.navbar-brand::before {
  content: "🍽️";
  font-size: 0.9rem;
  margin-right: 0.35rem;
  opacity: 0.9;
  top: -2px;
  position: relative;
}

/* Split brand: grote titel links, meta rechts */
.app-brand-bar {
  /* zit al in een .container en .navbar, dus alleen gedrag regelen */
}

/* Titel links – mag echt “loud” zijn */
.app-brand-left {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: #ffffff;
  line-height: 0px;
}

/* Emoji uit .navbar-brand::before blijft netjes vóór "FoodApp" komen */

/* Blok rechts met by 5446 + slogan */
.app-brand-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  /*gap: 0.1rem;*/
}

/* "by 5446" – klein, strak, techy */
.app-brand-by {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(255, 255, 255, 0.9);
}

/* Slogan – iets zachter eronder */
.app-brand-tagline {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: none;
  color: rgba(255, 255, 255, 0.78);
}

/* Mobile: links en rechts onder elkaar voor ruimte 
@media (max-width: 575.98px) {
  .app-brand-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
  }

  .app-brand-right {
    align-items: flex-start;
    text-align: left;
  }
}*/

.navbar .btn,
.navbar .nav-link {
  color: #111827 !important;
  font-size: 0.85rem;
}

.navbar .btn.text-light {
  color: #ffffff !important;
}

.navbar .btn.text-light:hover {
  color: #111827 !important;
}

/* Kleine chips-style buttons in de navbar */
.navbar .btn-sm {
  border-radius: var(--radius-pill);
  padding: 0.3rem 0.8rem;
  font-weight: 500;
  border-width: 1px;
}

/* Admin button als lichte outline */
.navbar .btn-outline-secondary {
  border-color: rgba(15, 23, 42, 0.18) !important;
  color: #111827 !important;
  background: #F9FAFB;
}

.navbar .btn-outline-secondary:hover {
  background: #E5E7EB !important;
  border-color: rgba(15, 23, 42, 0.3) !important;
}

/* Logout in rood maar wel modern */
.navbar #logoutBtn {
  border-radius: var(--radius-pill);
  border-width: 1px;
}

/* PAGE HEADERS */
main h2,
main h3 {
  font-weight: 650;
  letter-spacing: -0.02em;
  color: #111827;
}

main h2 {
  font-size: 1.5rem;
}

main h3 {
  font-size: 1.2rem;
  margin-top: 0;
}

/* Zoekbalk – pill + shadow + icoon */
#searchProducts {
  max-width: 260px;
  border-radius: var(--radius-pill);
  border: none;
  padding: 0.6rem 1rem 0.6rem 2.3rem;
  font-size: 0.9rem;
  background-color: #F9FAFB;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.12);
  transition: box-shadow 0.18s ease, transform 0.18s ease, background-color 0.18s ease;
  background-image: url("data:image/svg+xml,%3Csvg width='16' height='16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='7' cy='7' r='4.5' stroke='%239295B2'/%3E%3Cpath d='m10.5 10.5 3 3' stroke='%239295B2' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 12px center;
  background-size: 16px;
}

#searchProducts::placeholder {
  color: #9CA3AF;
}

#searchProducts:focus {
  outline: none;
  background-color: #FFFFFF;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
  transform: translateY(-1px);
}

/* CARDS – product tiles met hover effect */
.card {
  border: none;
  border-radius: var(--radius-lg);
  background-color: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.06);
  overflow: hidden;
  position: relative;
  transition: transform 0.15s ease-out, box-shadow 0.15s ease-out, background 0.15s ease-out;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0), rgba(123, 131, 255, 0.16));
  opacity: 0;
  transition: opacity 0.2s ease-out;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.18);
}

.card:hover::before {
  opacity: 1;
}

.card-body {
  padding: 1rem 1.1rem 1rem;
}

.card-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.2rem;
}

.card-text {
  color: var(--text-muted);
  font-size: 0.86rem;
}

/* Prijs badge als je die gebruikt */
.badge-price {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.7rem;
  border-radius: var(--radius-pill);
  background: rgba(38, 47, 141, 0.06);
  color: var(--primary-color);
  font-weight: 600;
  font-size: 0.8rem;
}

/* Buttons – pill, gradient en consistent */
.btn {
  border-radius: var(--radius-pill);
  font-weight: 500;
  font-size: 1rem;
  padding: 0.4rem 0.95rem;
  border-width: 1px;
}

.btn-primary,
.btn-success {
  background-image: linear-gradient(135deg, var(--primary-soft-alt), var(--primary-soft));
  border-color: transparent;
  color: #FFFFFF !important;
  box-shadow: 0px 6px 16px 2px rgb(76 81 191 / 26%);
}

.btn-primary:hover,
.btn-success:hover {
  filter: brightness(1.05);
  box-shadow: 0px 12px 20px 2px rgb(76 81 191 / 26%);
}

.btn-outline-primary,
.btn-outline-secondary {
  border-color: rgba(15, 23, 42, 0.12) !important;
  background: rgba(255, 255, 255, 0.94);
  color: var(--primary-color) !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.btn-outline-primary:hover,
.btn-outline-secondary:hover {
  background: rgba(38, 47, 141, 0.06) !important;
}

.btn.btn-sm {
    font-size: 0.8em  !important;
}
/* TABLES – meer padding en strakke layout */
.table {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
  border-collapse: separate;
  border-spacing: 0;
  margin-bottom: 0;
}

/* header */
.table thead {
  background-color: #333da4 !important;
  color: #FFFFFF  !important;
  border-bottom: none;
}

.table thead th {
  border-bottom: none !important;
  font-weight: 500;
  font-size: 0.85rem;
  padding: 0.8rem 1rem;
  vertical-align: middle;
  color: #ffffff;
  background-color: #333da4 !important;
}

/* cell padding & borders */
.table > :not(caption) > * > * {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.35);
  vertical-align: middle;
  font-size: 0.87rem;
}

/* laatste rij zonder zware border */
.table tbody tr:last-child td {
  border-bottom: none;
}

/* zebra + hover */
.table tbody tr:nth-of-type(odd) {
  background-color: #F9FAFB;
}

.table tbody tr:nth-of-type(even) {
  background-color: #FFFFFF;
}

.table tbody tr:hover {
  background-color: #EEF2FF;
}

/* table-sm ook netjes maken */
.table.table-sm > :not(caption) > * > * {
  padding: 0.6rem 0.9rem;
}

/* TODAY / HISTORY blocks – grid layout */
#todayOrders,
#orderHistory {
  display: grid;
  gap: 0.9rem;
}

/* Als je daar kaarten in stopt, zien ze er netjes uit */
#todayOrders .card,
#orderHistory .card {
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

/* Status / info messages */
#orderMessage {
  font-size: 0.9rem;
}

#orderMessage .alert {
  border-radius: var(--radius-pill);
  padding: 0.5rem 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

/* FOOTER – licht & subtiel */
/* --- Footer --- */
.app-footer {
  background: linear-gradient(
    180deg,
    rgba(249, 250, 251, 0.96),
    rgba(229, 231, 235, 0.98)
  );
  border-top: 1px solid rgba(148, 163, 184, 0.25);
  color: var(--text-muted);
  font-size: 0.8rem;
}

.app-footer .container {
  max-width: 1080px;
}

.app-footer-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary-soft), var(--primary-soft-alt));
  box-shadow: 0 0 0 4px rgba(76, 81, 191, 0.18);
  flex-shrink: 0;
}

.app-footer-badge {
  border-radius: 999px;
  padding: 0.18rem 0.65rem;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(255, 255, 255, 0.85);
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 0.03em;
}


/* Klein responsive detail */
@media (max-width: 575.98px) {
  main h2 {
    font-size: 1.3rem;
  }

  #searchProducts {
    max-width: 100%;
    margin-top: 0.75rem;
  }
}
