/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* ==========================================================================
   FIBU COLOR VARIABLES
   ========================================================================== */

:root {
  /* Fibu Brand Colors */
  --fibu-primary: #009f9d;
  --fibu-primary-dark: #007f7d;
  --fibu-primary-light: #00bfbd;
  --fibu-secondary: #fa542b;
  --fibu-secondary-dark: #d94520;
  --fibu-secondary-light: #fb7a58;
  --fibu-light: #fff6e8;
  --fibu-light-transparent: rgba(255, 246, 232, 0.5);

  /* Semantic Colors */
  --color-success: #28a745;
  --color-warning: #ffc107;
  --color-danger: #dc3545;
  --color-info: #17a2b8;

  /* Neutral Colors */
  --color-text: #2c3e50;
  --color-text-light: #6c757d;
  --color-text-muted: #95a5a6;
  --color-border: #e0e6ed;
  --color-bg: #ffffff;
  --color-bg-light: #f8f9fa;
  --color-bg-page: #f0f4f8;
  --color-card-bg: #ffffff;
  --color-shadow-sm: rgba(0, 0, 0, 0.05);
  --color-shadow-md: rgba(0, 0, 0, 0.1);
  --color-shadow-lg: rgba(0, 0, 0, 0.15);
}

/* ==========================================================================
   BASE STYLES - Mobile First
   ========================================================================== */

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--color-text);
  background-color: var(--color-bg-page);
}

/* ==========================================================================
   NAVIGATION
   ========================================================================== */

.navbar {
  background: linear-gradient(135deg, var(--fibu-primary) 0%, var(--fibu-primary-dark) 100%);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.navbar-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  font-size: 1.5rem;
  font-weight: bold;
  z-index: 1001;
}

.nav-logo {
  color: #fff;
  text-decoration: none;
  transition: opacity 0.3s;
  display: flex;
  align-items: center;
}

.nav-logo:hover {
  opacity: 0.9;
}

/* Hamburger Menu Button */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
  transition: all 0.3s ease;
}

.hamburger-line {
  width: 25px;
  height: 3px;
  background-color: #fff;
  border-radius: 3px;
  transition: all 0.3s ease;
}

.nav-hamburger.active .hamburger-line:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
}

.nav-hamburger.active .hamburger-line:nth-child(2) {
  opacity: 0;
}

.nav-hamburger.active .hamburger-line:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

/* Navigation Menu */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.nav-link {
  color: #fff;
  text-decoration: none;
  padding: 0.625rem 1.25rem;
  border-radius: 8px;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 0.95rem;
}

.nav-link:hover {
  background-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

/* User Section */
.nav-user {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.user-email {
  color: #fff;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.625rem 1rem;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
}

.btn-logout {
  background-color: var(--fibu-secondary);
  border: 2px solid var(--fibu-secondary);
  color: #fff;
  padding: 0.625rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-logout:hover {
  background-color: var(--fibu-secondary-dark);
  border-color: var(--fibu-secondary-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   CONTAINER & LAYOUT
   ========================================================================== */

.container {
  max-width: 100%;
  padding: 1rem;
  margin: 0 auto;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 3px solid var(--color-bg-light);
}

.page-header h1 {
  font-size: 2rem;
  font-weight: 800;
  color: var(--fibu-primary);
  letter-spacing: -0.03em;
  position: relative;
  display: inline-block;
}

.page-header h1::after {
  content: '';
  position: absolute;
  bottom: -0.5rem;
  left: 0;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--fibu-secondary) 0%, var(--fibu-secondary-light) 100%);
  border-radius: 2px;
}

.page-header-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   ALERTS
   ========================================================================== */

.alert {
  padding: 1rem;
  margin-bottom: 1rem;
  border-radius: 4px;
  border-left: 4px solid;
}

.alert-success {
  background-color: #d4edda;
  border-color: #28a745;
  color: #155724;
}

.alert-danger {
  background-color: #f8d7da;
  border-color: #dc3545;
  color: #721c24;
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
  min-height: 44px; /* Mobile touch target */
}

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

.btn-primary:hover {
  background-color: var(--fibu-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 159, 157, 0.3);
}

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

.btn-secondary:hover {
  background-color: var(--fibu-secondary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(250, 84, 43, 0.3);
}

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

.btn-info:hover {
  background-color: var(--fibu-primary);
  transform: translateY(-2px);
}

.btn-warning {
  background-color: var(--color-warning);
  color: #000;
}

.btn-warning:hover {
  background-color: #ffca2c;
  transform: translateY(-2px);
}

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

.btn-danger:hover {
  background-color: #c82333;
  transform: translateY(-2px);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  min-height: 36px;
}

/* ==========================================================================
   FORMS
   ========================================================================== */

.form-container {
  background: linear-gradient(to bottom, #ffffff 0%, #fafbfc 100%);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 2px 8px var(--color-shadow-sm), 0 1px 3px var(--color-shadow-md);
  border: 1px solid var(--color-border);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: #333;
}

.form-control,
.form-select {
  width: 100%;
  padding: 0.75rem;
  font-size: 1rem;
  border: 1px solid #ced4da;
  border-radius: 4px;
  background-color: #fff;
  transition: border-color 0.2s;
}

.form-control:focus,
.form-select:focus {
  outline: none;
  border-color: var(--fibu-primary);
  box-shadow: 0 0 0 3px rgba(0, 159, 157, 0.15);
}

.form-check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-check-input {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.form-check-label {
  cursor: pointer;
}

.form-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   TABLES
   ========================================================================== */

.table-responsive {
  overflow-x: auto;
  margin-top: 1rem;
}

.table {
  width: 100%;
  background-color: #fff;
  border-collapse: collapse;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.table thead {
  background-color: #f8f9fa;
}

.table th,
.table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid #dee2e6;
}

.table th {
  font-weight: 600;
  color: #495057;
}

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

.table tfoot {
  background-color: #f8f9fa;
  font-weight: bold;
}

.total-row td {
  color: var(--fibu-primary);
  font-weight: 600;
}

/* ==========================================================================
   FILTERS
   ========================================================================== */

.filters {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, var(--fibu-primary) 0%, var(--fibu-primary-dark) 100%);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 159, 157, 0.2), 0 2px 4px var(--color-shadow-md);
  position: relative;
  overflow: hidden;
}

.filters::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg width="40" height="40" xmlns="http://www.w3.org/2000/svg"><circle cx="20" cy="20" r="1" fill="white" opacity="0.1"/></svg>');
  pointer-events: none;
}

.filters .form-group {
  position: relative;
  z-index: 1;
}

.filters .form-group label {
  color: #ffffff;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.filters .form-control,
.filters .form-select {
  background-color: rgba(255, 255, 255, 0.95);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: var(--color-text);
  font-weight: 500;
}

.filters .form-control:focus,
.filters .form-select:focus {
  background-color: #ffffff;
  border-color: var(--fibu-secondary);
  box-shadow: 0 0 0 3px rgba(250, 84, 43, 0.2);
}

/* ==========================================================================
   ORDERS GRID
   ========================================================================== */

.orders-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

/* Clickable card wrapper */
.order-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.order-card {
  background: linear-gradient(to bottom right, #ffffff 0%, #fafbfc 100%);
  border-radius: 12px;
  padding: 1.75rem;
  box-shadow: 0 2px 8px var(--color-shadow-sm), 0 1px 3px var(--color-shadow-md);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-left: 4px solid var(--fibu-primary);
  position: relative;
  cursor: pointer;

  /* Fixed height to ensure consistent card sizes - increased to fit all content including "more items" */
  min-height: 470px;
  max-height: 470px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.order-card::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, var(--fibu-primary-light) 0%, transparent 70%);
  opacity: 0.05;
  border-radius: 50%;
  transform: translate(30%, -30%);
}

.order-card-link:hover .order-card {
  box-shadow: 0 8px 24px var(--color-shadow-md), 0 4px 12px var(--color-shadow-lg);
  transform: translateY(-4px);
  border-left-color: var(--fibu-secondary);
}

/* Ensure interactive elements remain clickable within the card */
.order-card .order-statuses,
.order-card .alegra-link {
  position: relative;
  z-index: 2;
}

.order-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.order-header h3 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--fibu-primary);
  margin: 0;
  letter-spacing: -0.02em;
}

.order-date {
  color: var(--color-text-light);
  font-size: 0.875rem;
  font-weight: 500;
  background-color: var(--color-bg-light);
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
}

.order-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.order-products {
  margin-bottom: 1rem;
  flex-shrink: 0;
  /* Fixed height for 2 products + the "more items" indicator */
  height: auto;
  max-height: none;
}

.order-item {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid #f0f0f0;
}

.order-item:last-child {
  border-bottom: none;
}

.order-item-more {
  padding: 0.5rem 0.75rem;
  color: var(--fibu-primary);
  font-weight: 700;
  font-size: 0.85rem;
  text-align: center;
  font-style: italic;
  background: linear-gradient(135deg, rgba(0, 159, 157, 0.08) 0%, rgba(0, 159, 157, 0.12) 100%);
  border-radius: 6px;
  margin-top: 0.4rem;
  border: 1px dashed var(--fibu-primary);
  opacity: 0.9;
}

.product-name {
  font-weight: 500;
}

.quantity {
  color: #6c757d;
}

.order-details {
  margin: 0.75rem 0 0 0;
  padding-top: 0.75rem;
  border-top: 2px solid #f0f0f0;
  flex-shrink: 0;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.25rem 0;
  gap: 0.5rem;
  min-height: 24px;
}

.detail-row .label {
  flex-shrink: 0;
  white-space: nowrap;
  font-size: 0.9rem;
  color: var(--color-text-light);
}

.detail-row .value {
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.9rem;
  font-weight: 500;
}

.detail-row.total {
  font-weight: bold;
  color: var(--fibu-primary);
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 2px solid var(--fibu-primary-light);
}

.detail-row.total .label,
.detail-row.total .value {
  font-size: 1.125rem;
  font-weight: bold;
}

.detail-row.alegra-row {
  /* Always show alegra row to maintain consistent card height */
  min-height: 38px;
  align-items: flex-start;
}

.detail-row.alegra-row .value {
  word-break: break-word;
  max-width: 70%;
  overflow-wrap: break-word;
  white-space: normal;
}

.alegra-placeholder {
  color: var(--color-text-light);
  font-style: italic;
  opacity: 0.5;
}

.alegra-link {
  color: var(--fibu-secondary);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s;
}

.alegra-link:hover {
  color: var(--fibu-secondary-dark);
  text-decoration: underline;
}

.order-statuses {
  display: flex;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.75rem;
  flex-wrap: wrap;
  flex-shrink: 0;
  align-self: flex-start;
  width: 100%;
}

.status-badge {
  display: inline-block;
  padding: 0.375rem 0.75rem;
  border-radius: 16px;
  font-size: 0.875rem;
  font-weight: 500;
}

/* Order Status Colors */
.status-order.status-received {
  background-color: #fff3cd;
  color: #856404;
  border: 1px solid #ffc107;
}

.status-order.status-in_production {
  background-color: #cfe2ff;
  color: #084298;
  border: 1px solid #0d6efd;
}

.status-order.status-ready {
  background-color: #d1e7dd;
  color: #0f5132;
  border: 1px solid #198754;
}

.status-order.status-delivered {
  background-color: #198754;
  color: #fff;
  border: 1px solid #146c43;
}

/* Billing Status Colors */
.status-billing.status-pending {
  background-color: #f8d7da;
  color: #842029;
  border: 1px solid #dc3545;
}

.status-billing.status-invoiced {
  background-color: #fff3cd;
  color: #856404;
  border: 1px solid #ffc107;
}

.status-billing.status-paid {
  background-color: #198754;
  color: #fff;
  border: 1px solid #146c43;
}

/* Status select styling - maintains badge appearance but clearly interactive */
.status-select {
  display: inline-block;
  padding: 0.375rem 0.75rem;
  border-radius: 16px;
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  padding-right: 2rem;
}

.status-select:hover {
  opacity: 0.85;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.status-select:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.2);
}

/* Dropdown arrow icon using inline SVG data URL */
/* Background image is added separately so it doesn't override background-color from status classes */
.status-select {
  background-image: url('data:image/svg+xml;charset=UTF-8,<svg width="12" height="8" viewBox="0 0 12 8" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1 1L6 6L11 1" stroke="currentColor" stroke-width="2" stroke-linecap="round"/></svg>');
  background-size: 12px;
  background-position: right 0.5rem center;
  background-repeat: no-repeat;
}

/* Maintain existing status color schemes */
/* Colors are inherited from .status-order.status-* and .status-billing.status-* classes */

.order-footer {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   ORDER ITEMS (Form)
   ========================================================================== */

.order-items-section {
  background-color: #f8f9fa;
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

.order-items-section h3 {
  margin-bottom: 1rem;
  font-size: 1.125rem;
}

.order-item-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  padding: 1rem;
  background-color: #fff;
  border-radius: 8px;
  margin-bottom: 1rem;
  border: 1px solid #dee2e6;
}

.total-display {
  background-color: #f8f9fa;
  padding: 1rem;
  border-radius: 8px;
  font-size: 1.25rem;
  text-align: right;
  margin: 1rem 0;
}

/* ==========================================================================
   ORDER SHOW PAGE
   ========================================================================== */

.order-show {
  background: linear-gradient(to bottom, #ffffff 0%, #fafbfc 100%);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 2px 8px var(--color-shadow-sm), 0 1px 3px var(--color-shadow-md);
  border: 1px solid var(--color-border);
}

.order-info {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

.info-group label {
  display: block;
  font-weight: 600;
  color: #6c757d;
  font-size: 0.875rem;
  margin-bottom: 0.25rem;
}

.info-group p {
  color: #333;
  font-size: 1rem;
}

.alegra-link {
  color: var(--fibu-primary);
  text-decoration: none;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  transition: all 0.2s;
  display: inline-block;
}

.alegra-link:hover {
  background-color: rgba(0, 159, 157, 0.1);
  text-decoration: underline;
  color: var(--fibu-primary-dark);
}

/* ==========================================================================
   PAGINATION
   ========================================================================== */

.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.pagination a,
.pagination span {
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  text-decoration: none;
  color: var(--fibu-primary);
  background-color: var(--color-bg);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.pagination .current {
  background-color: var(--fibu-primary);
  color: #fff;
  border-color: var(--fibu-primary);
}

.pagination a:hover {
  background-color: rgba(0, 159, 157, 0.1);
  border-color: var(--fibu-primary);
}

/* ==========================================================================
   UTILITY CLASSES
   ========================================================================== */

.no-data {
  text-align: center;
  padding: 3rem 1rem;
  color: #6c757d;
  font-size: 1.125rem;
}

/* ==========================================================================
   QUICK ORDER ENTRY
   ========================================================================== */

.quick-order-section {
  background: linear-gradient(135deg, var(--fibu-secondary) 0%, var(--fibu-secondary-dark) 100%);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(250, 84, 43, 0.25), 0 2px 4px var(--color-shadow-md);
  margin-bottom: 2rem;
  position: relative;
  overflow: hidden;
}

.quick-order-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.quick-order-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  color: #ffffff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 1;
}

.quick-order-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
  z-index: 1;
}

.quick-order-input-group {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.quick-order-input {
  flex: 1;
  min-width: 200px;
  padding: 0.875rem 1rem;
  font-size: 1rem;
  font-weight: 500;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  background-color: rgba(255, 255, 255, 0.95);
  transition: all 0.3s;
  color: var(--color-text);
}

.quick-order-input:focus {
  outline: none;
  border-color: #ffffff;
  background-color: #ffffff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-1px);
}

.quick-order-input::placeholder {
  color: var(--color-text-muted);
}

.quick-order-submit {
  white-space: nowrap;
  background-color: #ffffff;
  color: var(--fibu-secondary);
  border: 2px solid #ffffff;
  font-weight: 700;
  padding: 0.875rem 2rem;
  font-size: 1rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.quick-order-submit:hover {
  background-color: var(--fibu-secondary-dark);
  color: #ffffff;
  border-color: var(--fibu-secondary-dark);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  transform: translateY(-2px);
}

.quick-order-help {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
  font-weight: 500;
}

.quick-order-errors {
  margin-bottom: 0.5rem;
}

.quick-order-error {
  margin-bottom: 0;
}

/* ==========================================================================
   TABLET STYLES
   ========================================================================== */

@media (min-width: 768px) {
  .container {
    padding: 2rem;
  }

  .nav-links {
    width: auto;
    margin-top: 0;
  }

  .page-header h1 {
    font-size: 2rem;
  }

  .filters {
    grid-template-columns: repeat(2, 1fr);
  }

  .orders-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .order-item-row {
    grid-template-columns: 2fr 1fr 1fr auto;
    align-items: end;
  }

  .order-info {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================================================
   DESKTOP STYLES
   ========================================================================== */

@media (min-width: 1024px) {
  .container {
    max-width: 1200px;
  }

  .orders-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .order-info {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ==========================================================================
   MOBILE OPTIMIZATION FOR QUICK ORDER
   ========================================================================== */

@media (max-width: 767px) {
  .quick-order-input-group {
    flex-direction: column;
  }

  .quick-order-input {
    width: 100%;
  }

  .quick-order-submit {
    width: 100%;
    min-height: 48px; /* iOS touch target */
  }

  /* Slightly taller cards on mobile for better readability */
  .order-card {
    min-height: 490px;
    max-height: 490px;
  }
}

/* ==========================================================================
   AUTHENTICATION STYLES
   ========================================================================== */

.auth-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 80vh;
  padding: 1rem;
}

.auth-card {
  background: linear-gradient(to bottom, #ffffff 0%, #fafbfc 100%);
  padding: 2.5rem;
  border-radius: 12px;
  box-shadow: 0 4px 16px var(--color-shadow-md), 0 2px 8px var(--color-shadow-lg);
  max-width: 400px;
  width: 100%;
  border: 1px solid var(--color-border);
}

.auth-card h1 {
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
  text-align: center;
  color: var(--fibu-primary);
}

.auth-description {
  text-align: center;
  color: #666;
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

.auth-card .form-group {
  margin-bottom: 1.5rem;
}

.auth-card .form-check {
  margin-bottom: 1rem;
}

.auth-card .actions {
  margin-top: 1.5rem;
}

.btn-block {
  width: 100%;
}

/* Password toggle */
.password-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.password-input-wrapper .form-control {
  padding-right: 3rem;
}

.password-toggle {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: 0.25rem;
  cursor: pointer;
  color: #6c757d;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s;
}

.password-toggle:hover {
  color: #495057;
}

.password-toggle:focus {
  outline: none;
  color: var(--fibu-primary);
}

.password-icon {
  width: 20px;
  height: 20px;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */

.app-footer {
  background-color: #fff;
  border-top: 1px solid #dee2e6;
  margin-top: 3rem;
  padding: 1.5rem;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

.footer-version {
  color: #6c757d;
  font-size: 0.875rem;
  margin: 0;
}

/* ==========================================================================
   MOBILE NAVIGATION (Hamburger Menu)
   ========================================================================== */

@media (max-width: 767px) {
  .nav-hamburger {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: linear-gradient(135deg, var(--fibu-primary) 0%, var(--fibu-primary-dark) 100%);
    flex-direction: column;
    gap: 0;
    padding: 5rem 2rem 2rem;
    box-shadow: -4px 0 10px rgba(0, 0, 0, 0.1);
    transition: right 0.3s ease;
    overflow-y: auto;
  }

  .nav-menu.nav-menu-open {
    right: 0;
  }

  .nav-links {
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
    margin-bottom: 2rem;
  }

  .nav-link {
    width: 100%;
    padding: 1rem;
    text-align: left;
    font-size: 1rem;
  }

  .nav-user {
    flex-direction: column;
    width: 100%;
    gap: 1rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
  }

  .user-email {
    width: 100%;
    text-align: center;
    padding: 1rem;
  }

  .btn-logout {
    width: 100%;
    padding: 1rem;
    font-size: 1rem;
  }
}

/* Desktop adjustments */
@media (min-width: 768px) {
  .nav-hamburger {
    display: none;
  }
}
