/* ============================================
   Schaui's Lunch — Design inspired by schauis.com
   ============================================ */

:root {
  --primary: #c8102e;
  --primary-dark: #a00d24;
  --primary-light: #e8354d;
  --secondary: #f5a623;
  --secondary-dark: #d4901c;
  --bg-dark: #1a1a1a;
  --bg-card: #2a2a2a;
  --bg-card-hover: #333333;
  --bg-input: #353535;
  --text: #f0f0f0;
  --text-muted: #999;
  --text-dark: #1a1a1a;
  --success: #2ecc71;
  --success-bg: rgba(46, 204, 113, 0.15);
  --warning: #f39c12;
  --warning-bg: rgba(243, 156, 18, 0.15);
  --danger: #e74c3c;
  --danger-bg: rgba(231, 76, 60, 0.15);
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 20px rgba(0,0,0,0.3);
  --shadow-hover: 0 8px 30px rgba(0,0,0,0.4);
  --transition: all 0.2s ease;
}

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

body {
  font-family: 'Nunito', sans-serif;
  background: var(--bg-dark);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---- Navbar ---- */
.navbar {
  background: rgba(26, 26, 26, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--primary);
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}

.brand-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
}

.brand-text {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
}

.nav-link:hover {
  color: var(--text);
}

/* ---- Buttons ---- */
.btn {
  display: inline-block;
  padding: 10px 22px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
  transition: var(--transition);
  text-align: center;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(200, 16, 46, 0.4);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid #444;
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
}

.btn-success {
  background: var(--success);
  color: #fff;
}

.btn-warning {
  background: var(--warning);
  color: var(--text-dark);
}

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 0.85rem;
}

.btn-lg {
  padding: 14px 32px;
  font-size: 1.1rem;
}

.btn-block {
  display: block;
  width: 100%;
}

/* ---- Alerts ---- */
.alert {
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
  font-weight: 600;
  animation: slideIn 0.3s ease;
}

.alert-success {
  background: var(--success-bg);
  color: var(--success);
  border: 1px solid var(--success);
}

.alert-danger {
  background: var(--danger-bg);
  color: var(--danger);
  border: 1px solid var(--danger);
}

@keyframes slideIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---- Hero ---- */
.hero {
  text-align: center;
  padding: 60px 20px;
}

.hero-logo {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 20px;
  border: 3px solid var(--primary);
  box-shadow: 0 0 30px rgba(200, 16, 46, 0.3);
}

.hero-title {
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 10px;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 30px;
}

/* ---- Sections ---- */
.main-content {
  flex: 1;
  padding: 30px 20px;
}

.section {
  margin-bottom: 40px;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 8px;
  color: var(--text);
}

.section-subtitle {
  color: var(--text-muted);
  margin-bottom: 20px;
}

.empty-state {
  text-align: center;
  color: var(--text-muted);
  padding: 40px;
  font-size: 1.1rem;
}

/* ---- Rounds Grid ---- */
.rounds-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.round-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 20px;
  text-decoration: none;
  color: var(--text);
  transition: var(--transition);
  box-shadow: var(--shadow);
  border: 1px solid transparent;
}

.round-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary);
}

.round-card-header {
  margin-bottom: 12px;
}

.round-status {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-open {
  background: var(--success-bg);
  color: var(--success);
  border: 1px solid var(--success);
}

.status-closed {
  background: var(--danger-bg);
  color: var(--danger);
  border: 1px solid var(--danger);
}

.round-card-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.round-card-creator {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.round-card-stats {
  display: flex;
  gap: 20px;
  margin-bottom: 8px;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--secondary);
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.round-card-delete {
  margin-top: 10px;
}

.round-card-driver,
.round-card-deadline {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ---- Round Detail ---- */
.round-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 16px;
}

.round-status-big {
  padding: 8px 20px;
  border-radius: 25px;
  font-weight: 800;
  font-size: 1rem;
  text-transform: uppercase;
}

.deadline-info {
  color: var(--secondary);
  font-size: 0.95rem;
  margin-top: 4px;
}

.round-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.stats-bar {
  display: flex;
  gap: 20px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.stat-box {
  background: var(--bg-card);
  padding: 16px 24px;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  min-width: 120px;
}

.stat-box .stat-number {
  font-size: 1.4rem;
}

/* ---- Driver Section ---- */
.driver-section {
  background: var(--bg-card);
  padding: 20px;
  border-radius: var(--radius);
  margin-bottom: 30px;
}

.driver-section h3 {
  margin-bottom: 12px;
  color: var(--secondary);
}

.driver-form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.driver-form input {
  flex: 1;
  min-width: 150px;
}

/* ---- Orders Grid ---- */
.orders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.order-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 16px;
  border-left: 4px solid var(--danger);
}

.order-paid {
  border-left-color: var(--success);
}

.order-unpaid {
  border-left-color: var(--warning);
}

.order-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.order-name {
  font-size: 1.05rem;
}

.order-total {
  font-weight: 800;
  color: var(--secondary);
  font-size: 1.1rem;
}

.order-items-list {
  list-style: none;
  margin-bottom: 8px;
}

.order-items-list li {
  display: flex;
  justify-content: space-between;
  padding: 3px 0;
  font-size: 0.9rem;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.item-subtotal {
  font-weight: 600;
  color: var(--text);
}

.order-note {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 8px;
}

.order-card-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

/* ---- Forms ---- */
.form-card {
  background: var(--bg-card);
  padding: 30px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  max-width: 600px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-weight: 700;
  color: var(--text);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #444;
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(200, 16, 46, 0.2);
}

.form-hint {
  display: block;
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ---- Menu (Order Form) ---- */
.menu-container {
  margin: 20px 0;
}

.menu-heading {
  font-size: 1.4rem;
  color: var(--primary);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--primary);
}

.menu-category {
  margin-bottom: 24px;
}

.category-title {
  font-size: 1.1rem;
  color: var(--secondary);
  margin-bottom: 10px;
  padding: 8px 12px;
  background: rgba(245, 166, 35, 0.1);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--secondary);
}

.menu-items {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.menu-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: var(--bg-input);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.menu-item:hover {
  background: var(--bg-card-hover);
}

.menu-item-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.menu-item-name {
  font-weight: 700;
  font-size: 0.95rem;
}

.menu-item-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.menu-item-price {
  color: var(--secondary);
  font-weight: 800;
  font-size: 0.95rem;
}

.menu-item-qty {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: 16px;
}

.qty-btn {
  width: 34px;
  height: 34px;
  border: 2px solid #555;
  border-radius: 50%;
  background: var(--bg-card);
  color: var(--text);
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  line-height: 1;
}

.qty-btn:hover {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}

.qty-input {
  width: 40px;
  text-align: center;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 1.1rem;
  font-weight: 700;
  font-family: inherit;
  -moz-appearance: textfield;
}

.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
}

/* ---- Order Summary ---- */
.order-summary {
  background: rgba(200, 16, 46, 0.1);
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  padding: 20px;
  margin: 20px 0;
}

.order-summary h3 {
  color: var(--primary);
  margin-bottom: 12px;
}

.summary-line {
  display: flex;
  justify-content: space-between;
  padding: 4px 0;
  font-size: 0.95rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.summary-total {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 2px solid var(--primary);
  font-size: 1.2rem;
  font-weight: 800;
  text-align: right;
  color: var(--secondary);
}

/* ---- Driver View ---- */
.driver-view-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 10px;
}

.driver-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
}

.driver-table th {
  background: var(--primary);
  color: #fff;
  padding: 12px 16px;
  text-align: left;
  font-weight: 700;
}

.driver-table td {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  vertical-align: top;
}

.driver-table tfoot td {
  background: rgba(200, 16, 46, 0.1);
  font-size: 1.05rem;
}

.paypal-info {
  margin-top: 20px;
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  text-align: center;
}

/* ---- Summary Table ---- */
.summary-section {
  margin-bottom: 30px;
}

.summary-table-wrap {
  overflow-x: auto;
}

.summary-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
}

.summary-table th {
  background: var(--secondary-dark);
  color: #fff;
  padding: 10px 16px;
  text-align: left;
  font-weight: 700;
}

.summary-table td {
  padding: 10px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.summary-table tfoot td {
  background: rgba(245, 166, 35, 0.1);
  font-size: 1.05rem;
}

.summary-qty {
  font-weight: 800;
  color: var(--secondary);
  font-size: 1.05rem;
}

/* ---- Footer ---- */
.footer {
  background: var(--bg-card);
  border-top: 2px solid var(--primary);
  padding: 20px 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: auto;
}

/* ---- Login Page ---- */
.login-body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--bg-dark);
  background-image:
    radial-gradient(ellipse at 30% 20%, rgba(200, 16, 46, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 80%, rgba(245, 166, 35, 0.08) 0%, transparent 50%);
}

.login-container {
  width: 100%;
  max-width: 420px;
  padding: 20px;
}

.login-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 40px 30px;
  box-shadow: var(--shadow);
  text-align: center;
  border: 1px solid rgba(255,255,255,0.05);
}

.login-logo {
  margin-bottom: 20px;
}

.login-logo-img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
}

.login-title {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 8px;
}

.login-badge {
  display: inline-block;
  background: rgba(200, 16, 46, 0.15);
  color: var(--primary);
  font-weight: 800;
  font-size: 0.8rem;
  padding: 4px 16px;
  border-radius: 20px;
  border: 1px solid var(--primary);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 24px;
}

.login-form .form-group {
  text-align: left;
}

.login-form .form-group input {
  text-align: center;
  font-size: 1.1rem;
  letter-spacing: 1px;
}

/* ---- Hagedorn Navbar Badge ---- */
.nav-intern-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(200, 16, 46, 0.15);
  color: var(--primary);
  font-weight: 800;
  font-size: 0.75rem;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid rgba(200, 16, 46, 0.4);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-hagedorn-logo {
  width: 22px;
  height: 22px;
  border-radius: 50%;
}

.nav-logout {
  font-size: 0.85rem;
  opacity: 0.6;
}

.nav-logout:hover {
  opacity: 1;
  color: var(--danger) !important;
}

/* ---- Hero Hagedorn ---- */
.hero-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-bottom: 20px;
}

.hero-logo-hagedorn {
  border-color: #1a3a5c;
  box-shadow: 0 0 30px rgba(26, 58, 92, 0.3);
}

.hero-intern-badge {
  display: inline-block;
  background: rgba(200, 16, 46, 0.15);
  color: var(--primary);
  font-weight: 800;
  font-size: 0.85rem;
  padding: 6px 20px;
  border-radius: 20px;
  border: 1px solid var(--primary);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}

/* ---- Error ---- */
.error-section {
  text-align: center;
  padding: 60px 20px;
}

.error-section h1 {
  font-size: 2rem;
  color: var(--primary);
  margin-bottom: 12px;
}

/* ---- Responsive ---- */
@media (max-width: 600px) {
  .hero-title { font-size: 2rem; }
  .hero-logo { width: 80px; height: 80px; }
  .hero-logos { gap: 12px; }
  .nav-intern-badge { display: none; }
  .form-card { padding: 20px; }
  .round-header { flex-direction: column; }
  .round-actions { flex-direction: column; }
  .round-actions .btn { width: 100%; }
  .stats-bar { flex-direction: column; }
  .driver-form { flex-direction: column; }
  .driver-form input { width: 100%; }
  .menu-item { flex-direction: column; align-items: flex-start; gap: 8px; }
  .menu-item-qty { margin-left: 0; align-self: flex-end; }
  .order-form { max-width: 100%; }
}

/* ---- Print ---- */
@media print {
  .navbar, .footer, .no-print, .round-actions, .btn { display: none !important; }
  body { background: #fff; color: #000; }
  .driver-table th { background: #333; color: #fff; -webkit-print-color-adjust: exact; }
  .driver-table td { border-bottom: 1px solid #ccc; }
}
