/* ================================
   TRAILER RENTAL - MOBILE FIRST
   Simple, Clean, Fast
   ================================ */

/* RESET & BASE */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Colors - friendly neighbor, not corporate */
  --primary: #2563eb;      /* Clear blue - trustworthy */
  --primary-dark: #1e40af;
  --text-dark: #1f2937;
  --text-medium: #4b5563;
  --text-light: #6b7280;
  --bg-light: #f9fafb;
  --bg-white: #ffffff;
  --border: #e5e7eb;
  --success: #059669;
  --warning: #d97706;

  /* Typography */
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-size-base: 16px;

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --spacing-xl: 2.75rem;
  --spacing-xxl: 3.25rem;

  /* Layout */
  --max-width: 1200px;
  --border-radius: 8px;
}

body {
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--text-dark);
  background: var(--bg-white);
  -webkit-font-smoothing: antialiased;
}

/* TYPOGRAPHY */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--spacing-md);
  color: var(--text-dark);
}

h1 { font-size: 2rem; margin-bottom: var(--spacing-lg); }
h2 { font-size: 1.5rem; margin-bottom: var(--spacing-md); }
h3 { font-size: 1.25rem; }

p {
  margin-bottom: var(--spacing-sm);
  color: var(--text-medium);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--primary-dark);
}

/* Accessibility: Focus styles */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* Skip to content link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary);
  color: white;
  padding: 8px;
  text-decoration: none;
  z-index: 100;
}

.skip-link:focus {
  top: 0;
}

/* LAYOUT */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--spacing-sm);
}

/* HEADER & NAVIGATION */
header {
  background: var(--bg-white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-sm) 0;
}

.logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-dark);
}

.nav-links {
  display: flex;
  gap: var(--spacing-md);
  list-style: none;
}

.nav-links a {
  color: var(--text-medium);
  font-weight: 500;
  font-size: 0.9rem;
}

.nav-links a:hover {
  color: var(--primary);
}

/* HERO SECTION */
.hero {
  background-color: #1e40af !important; /* Fallback solid color */
  background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #2563eb 100%) !important;
  color: white !important;
  padding: var(--spacing-xl) 0;
  text-align: center;
  min-height: 400px;
  display: flex;
  align-items: center;
}

.hero .container {
  width: 100%;
}

.hero h1 {
  color: white !important;
  font-size: 1.75rem;
  margin-bottom: var(--spacing-sm);
  text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.hero .subheadline {
  font-size: 1rem;
  margin-bottom: var(--spacing-md);
  opacity: 0.95;
  color: white !important;
  text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.hero-specs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--spacing-sm);
  margin: var(--spacing-md) 0;
  font-size: 0.9rem;
}

.spec-badge {
  background: rgba(255,255,255,0.2);
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: 20px;
  backdrop-filter: blur(10px);
}

.hero-cta-group {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
  margin: var(--spacing-lg) 0;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--spacing-md);
  margin-top: var(--spacing-lg);
  font-size: 0.9rem;
  opacity: 0.95;
  color: white;
}

.trust-row span {
  white-space: nowrap;
}

/* BUTTONS */
.btn {
  display: inline-block;
  padding: 0.875rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--border-radius);
  border: none;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s ease;
  min-height: 48px; /* Mobile tap target */
  line-height: 1.4;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  color: white;
  background: var(--primary);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  filter: brightness(1.1);
}

.btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-secondary {
  background: #6b7280;
  color: white;
  border: none;
}

.btn-secondary:hover {
  background: #4b5563;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(107, 114, 128, 0.3);
}

/* Admin Dashboard Action Buttons */
.btn-approve {
  background: #16a34a;
  color: white;
}

.btn-approve:hover {
  background: #15803d;
  box-shadow: 0 4px 12px rgba(22, 163, 74, 0.3);
}

.btn-reject {
  background: #dc2626;
  color: white;
}

.btn-reject:hover {
  background: #b91c1c;
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}

.btn-respond {
  background: #2563eb;
  color: white;
}

.btn-respond:hover {
  background: #1d4ed8;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-save {
  background: #4f46e5;
  color: white;
}

.btn-save:hover {
  background: #4338ca;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.btn-cancel {
  background: #6b7280;
  color: white;
}

.btn-cancel:hover {
  background: #4b5563;
  box-shadow: 0 4px 12px rgba(107, 114, 128, 0.3);
}

.btn-large {
  width: 100%;
  font-size: 1.125rem;
  padding: var(--spacing-md);
}

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

/* Hero Section Button Overrides (for white buttons on blue background) */
.hero .btn-primary {
  background: var(--bg-white);
  color: var(--primary);
}

.hero .btn-primary:hover {
  background: var(--bg-white);
  color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.hero .btn-secondary {
  background: transparent;
  color: white;
  border: 2px solid white;
}

.hero .btn-secondary:hover {
  background: white;
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* SECTIONS */
section {
  padding: var(--spacing-xxl) 0;
}

section:nth-child(even):not(.hero) {
  background: var(--bg-light);
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-xl);
}

/* PRICING CARD */
.pricing-simple {
  background: var(--bg-white);
  padding: var(--spacing-lg);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  margin-bottom: var(--spacing-lg);
}

.price-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-md) 0;
  border-bottom: 1px solid var(--border);
}

.price-item:last-child {
  border-bottom: none;
  margin-bottom: var(--spacing-md);
}

.price-label-with-icon {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.price-icon {
  font-size: 1.5rem;
  line-height: 1;
}

.price-label {
  font-weight: 600;
  color: var(--text-dark);
  font-size: 1rem;
}

.price-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary);
  display: flex;
  align-items: baseline;
}

.price-unit {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-medium);
  margin-left: 0.25rem;
}

.pricing-note {
  margin: var(--spacing-md) 0 0 0;
  padding-top: var(--spacing-md);
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--text-medium);
  text-align: center;
  line-height: 1.6;
}

/* CARDS */
.card-grid {
  display: grid;
  gap: var(--spacing-md);
  margin-top: var(--spacing-lg);
}

.card {
  background: var(--bg-white);
  padding: var(--spacing-lg);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  border: 1px solid rgba(0,0,0,0.05);
}

.card h3 {
  margin-top: 0;
}

/* FEATURES / USES LIST */
.features-grid {
  display: grid;
  gap: var(--spacing-sm);
  margin: var(--spacing-md) 0;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm);
  background: var(--bg-light);
  border-radius: var(--border-radius);
}

.feature-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

/* FORMS */
.form-group {
  margin-bottom: var(--spacing-md);
}

label {
  display: block;
  font-weight: 600;
  margin-bottom: var(--spacing-xs);
  color: var(--text-dark);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select,
textarea {
  width: 100%;
  padding: var(--spacing-sm);
  font-size: 1rem;
  border: 2px solid var(--border);
  border-radius: var(--border-radius);
  font-family: var(--font-body);
  min-height: 48px; /* Mobile tap target */
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

.radio-group,
.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.radio-option,
.checkbox-option {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm);
  background: var(--bg-light);
  border-radius: var(--border-radius);
  cursor: pointer;
  min-height: 48px;
}

input[type="radio"],
input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.form-note {
  font-size: 0.875rem;
  color: var(--text-light);
  margin-top: var(--spacing-xs);
}

.required {
  color: var(--warning);
}

/* COST CALCULATOR */
.cost-calculator {
  background: var(--bg-light);
  padding: var(--spacing-lg);
  border-radius: var(--border-radius);
  margin: var(--spacing-lg) 0;
  border: 2px solid var(--primary);
}

.cost-breakdown {
  margin: var(--spacing-md) 0;
}

.cost-row {
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-xs) 0;
  color: var(--text-medium);
}

.cost-total {
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-sm) 0;
  border-top: 2px solid var(--border);
  margin-top: var(--spacing-sm);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-dark);
}

/* PHOTO GALLERY */
.photo-gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--spacing-md);
  margin: var(--spacing-xl) 0;
}

.photo-item {
  margin: 0;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  transition: transform 0.2s, box-shadow 0.2s;
}

.photo-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.photo-gallery img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

.photo-gallery figcaption {
  padding: var(--spacing-sm);
  background: var(--bg-white);
  text-align: center;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-medium);
}

/* FOOTER */
footer {
  background: var(--text-dark);
  color: white;
  padding: var(--spacing-lg) 0;
  margin-top: var(--spacing-xl);
  text-align: center;
}

footer p {
  color: rgba(255,255,255,0.7);
  margin: 0;
}

/* CONTACT BUTTONS */
.contact-buttons {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
  margin: var(--spacing-md) 0;
}

.contact-btn {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md);
  background: var(--bg-white);
  border: 2px solid var(--border);
  border-radius: var(--border-radius);
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
  min-height: 60px;
}

.contact-btn:hover {
  border-color: var(--primary);
  background: var(--bg-light);
}

.contact-icon {
  font-size: 1.5rem;
}

/* STICKY CTA (Mobile) */
.sticky-cta {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  padding: var(--spacing-sm);
  padding-bottom: calc(var(--spacing-sm) + env(safe-area-inset-bottom));
  box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
  z-index: 90;
  min-height: 56px;
  display: flex;
  align-items: center;
}

/* Add bottom padding on mobile to prevent content overlap */
@media (max-width: 767px) {
  body {
    padding-bottom: 72px;
  }
}

/* ADMIN DASHBOARD */
.dashboard-grid {
  display: grid;
  gap: var(--spacing-md);
  margin-top: var(--spacing-lg);
}

.dashboard-card {
  background: white;
  padding: var(--spacing-lg);
  border-radius: var(--border-radius);
  border: 1px solid var(--border);
}

.dashboard-card h3 {
  margin-top: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: 12px;
}

.badge-pending {
  background: #fef3c7;
  color: #92400e;
}

.badge-approved {
  background: #d1fae5;
  color: #065f46;
}

.request-item {
  padding: var(--spacing-sm);
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  margin-bottom: var(--spacing-sm);
}

.request-actions {
  display: flex;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-sm);
}

/* MOBILE SPECIFIC */
@media (max-width: 767px) {
  .hero {
    padding: 2rem 0;
    min-height: 350px;
  }
}

/* TABLET & UP */
@media (min-width: 768px) {
  h1 { font-size: 2.5rem; }
  .hero h1 { font-size: 2.5rem; }

  .hero-cta-group {
    flex-direction: row;
    justify-content: center;
  }

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

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

  .photo-gallery img {
    height: 240px;
  }

  .contact-buttons {
    flex-direction: row;
  }

  .sticky-cta {
    display: none; /* Hide on larger screens */
  }

  .nav-links {
    gap: var(--spacing-lg);
  }
}

/* DESKTOP */
@media (min-width: 1024px) {
  .card-grid {
    grid-template-columns: repeat(3, 1fr);
  }

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

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

/* UTILITY CLASSES */
.text-center { text-align: center; }
.text-muted { color: var(--text-light); }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mb-sm { margin-bottom: var(--spacing-sm); }
.mb-md { margin-bottom: var(--spacing-md); }
.mb-lg { margin-bottom: var(--spacing-lg); }
.hidden { display: none; }
