/* Core Crew Logistics: Professional Logistics Website Theme (2025) */

/* --- Font imports --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;900&display=swap');

:root {
  /* --- Color palette: professional logistics --- */
  --primary: #1846a3;
  --primary-dark: #143776;
  --primary-light: #2563eb;
  --accent-green: #2ecc71;
  --accent-orange: #f7b731;
  --background: #fff;
  --surface: #fff;
  --surface-dark: #f8fafc;
  --surface-darker: #e2e8f0;
  --text: #1a2636;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --border: #e5e9f2;
  --border-light: #f1f5f9;
  --shadow: 0 4px 32px 0 rgba(16, 42, 72, 0.08);
  --shadow-lg: 0 8px 40px 0 rgba(16, 42, 72, 0.12);

  /* Spacing system */
  --space-xs: 3px;
  --space-sm: 6px;
  --space-md: 12px;
  --space-lg: 18px;
  --space-xl: 26px;
  --space-2xl: 34px;
  --space-3xl: 42px;
}

/* --- Reset and base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--background);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 15px;
  line-height: 1.45;
  min-height: 100vh;
  overflow-x: hidden;
}

@media (max-width: 768px) {
  html, body {
    font-size: 13px;
  }
}
@media (max-width: 480px) {
  html, body {
    font-size: 12px;
  }
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--space-sm) 0;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.02em;
  line-height: 1.12;
}

h1 { font-size: 1.3rem; }
h2 { font-size: 1.15rem; }
h3 { font-size: 1rem; }
h4 { font-size: 0.95rem; }

p, label, li, td, th {
  color: var(--text-muted);
  font-weight: 400;
  line-height: 1.35;
  margin: 0 0 var(--space-xs) 0;
  font-size: 1.03rem;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: all 0.2s ease;
  font-size: 1.03rem;
}

a:hover {
  color: var(--accent-green);
  text-decoration: underline;
}

/* --- Container and layout --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
  width: 100%;
  background: transparent;
}

.section {
  margin: var(--space-xl) 0;
}

.section-centered {
  text-align: center;
}

.section-title {
  font-size: 1.17rem;
  color: var(--primary);
  margin-bottom: var(--space-lg);
  text-align: center;
}

/* --- Grid systems --- */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-lg);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-lg);
}

.what-we-do-grid {
  margin-top: var(--space-lg);
}

/* --- Navigation --- */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 20px 0 rgba(24, 70, 163, 0.06);
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 54px;
  padding-top: var(--space-sm);
  padding-bottom: var(--space-sm);
  min-width: 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 18px;
  font-weight: 700;
  font-size: 2rem;
  color: var(--primary);
  letter-spacing: -0.01em;
  flex-shrink: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-right: 28px;
}
.logo {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 2px 12px -2px rgba(24, 70, 163, 0.3);
  flex-shrink: 0;
}
.site-header nav {
  display: flex;
  align-items: center;
  gap: 13px;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
  min-width: 0;
  flex-shrink: 1;
}
.site-header nav::-webkit-scrollbar { display: none; }
.site-header nav a, .site-header nav .btn {
  font-size: 1.25rem;
  padding: 11px 21px;
  min-width: 0;
  max-width: 100vw;
  white-space: nowrap;
  word-break: normal;
  box-sizing: border-box;
  flex-shrink: 0;
}
/* Hide Apply Now button in header on all screens */
.site-header nav a.btn.primary {
  display: none !important;
}

@media (max-width: 1100px) {
  .site-header .brand { font-size: 1.5rem; gap: 10px; margin-right: 16px; }
  .site-header .logo { width: 40px; height: 40px;}
  .site-header nav a, .site-header nav .btn { font-size: 1.1rem; padding: 9px 10px;}
}
@media (max-width: 900px) {
  .site-header .container { padding-left: 6px; padding-right: 6px; }
  .site-header .brand { font-size: 1.25rem; gap: 8px; margin-right: 10px; }
  .site-header .logo { width: 34px; height: 34px;}
  .site-header nav a, .site-header nav .btn { font-size: 1.03rem; padding: 8px 8px;}
}
@media (max-width: 700px) {
  .site-header .brand { font-size: 1rem; gap: 6px; margin-right: 7px; }
  .site-header .logo { width: 26px; height: 26px;}
  .site-header nav a, .site-header nav .btn { font-size: 0.97rem; padding: 7px 6px;}
}
@media (max-width: 540px) {
  .site-header .brand { font-size: 0.88rem; gap: 3px; margin-right: 4px;}
  .site-header .logo { width: 19px; height: 19px;}
  .site-header nav a, .site-header nav .btn { font-size: 0.93rem; padding: 6px 2px;}
}
@media (max-width: 410px) {
  .site-header .brand { font-size: 0.75rem; gap: 2px; margin-right: 2px;}
  .site-header .logo { width: 14px; height: 14px;}
  .site-header nav a, .site-header nav .btn { font-size: 0.9rem; padding: 5px 1px;}
}

/* HORIZONTAL SCROLL INDICATOR - NAV */
.site-header nav {
  background:
    linear-gradient(to right, rgba(255,255,255,0), rgba(255,255,255,1) 85%) 100% 50%/40px 100% no-repeat,
    linear-gradient(to left, rgba(255,255,255,0), rgba(255,255,255,1) 85%) 0 50%/40px 100% no-repeat;
  background-attachment: local, local;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  padding: 10px 15px;
  font-weight: 600;
  font-size: 1.04rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
  min-height: 38px;
}

.btn.primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: white;
  box-shadow: 0 2px 8px 0 rgba(24, 70, 163, 0.1);
}

.btn.primary:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  box-shadow: 0 4px 14px 0 rgba(24, 70, 163, 0.15);
  transform: translateY(-1px);
  text-decoration: none;
  color: white;
}

.btn.ghost {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--border);
}

.btn.ghost:hover {
  background: var(--surface-dark);
  border-color: var(--primary);
  color: var(--primary);
  text-decoration: none;
}

/* --- Back Button --- */
.back-btn, .btn.ghost.back-float {
  position: fixed;
  top: 76px !important; /* Push below header (header min-height is 54px + spacing) */
  left: 2rem;
  z-index: 1100; /* Higher than header */
  background: #eee;
  border: none;
  padding: 0.7rem 1.5rem;
  color: #1846a3;
  font-weight: bold;
  border-radius: 4px;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  transition: background 0.2s;
}
.back-btn:hover, .btn.ghost.back-float:hover {
  background: #d6eaff;
}

/* --- Hero section --- */
.hero {
  padding: var(--space-xl) 0;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: var(--space-xl);
  align-items: center;
  min-height: 270px;
}

.hero-title {
  font-size: 1.17rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: var(--space-sm);
  line-height: 1.1;
}

.hero-desc {
  font-size: 1.04rem;
  color: var(--text-muted);
  margin-bottom: var(--space-md);
  line-height: 1.35;
}

.hero .actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-top: var(--space-sm);
}

.hero-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

/* --- Stats Section --- */
.stats-section {
  margin: var(--space-xl) 0;
  padding: var(--space-lg) 0;
  background: var(--surface-dark);
  border-radius: 12px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: var(--space-md);
  text-align: center;
}

.stat {
  padding: var(--space-md);
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px 0 rgba(24, 70, 163, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px 0 rgba(24, 70, 163, 0.10);
}

.stat-icon {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: var(--space-xs);
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--primary), var(--accent-green));
  border-radius: 50%;
  margin: 0 auto var(--space-xs) auto;
}

.stat-icon svg {
  width: 18px;
  height: 18px;
  stroke: white;
  stroke-width: 2;
}

.stat-number {
  font-size: 1.13rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: var(--space-xs);
  line-height: 1;
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.98rem;
  font-weight: 500;
}

/* --- Cards --- */
.card {
  background: var(--surface);
  border-radius: 10px;
  box-shadow: 0 2px 10px 0 rgba(24, 70, 163, 0.05);
  border: 1px solid var(--border-light);
  padding: var(--space-md);
  transition: all 0.3s ease;
  height: 100%;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px 0 rgba(24, 70, 163, 0.10);
}

.card h4 {
  color: var(--primary);
  font-size: 1.01rem;
  margin-bottom: var(--space-xs);
}

.card p {
  color: var(--text-muted);
  line-height: 1.35;
  font-size: .97rem;
}

/* --- Contact Section --- */
.contact-left-extreme {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: var(--space-lg) 0;
  margin: var(--space-lg) 0;
  background: var(--surface-dark);
  border-radius: 12px;
  padding: var(--space-lg);
}

.contact-heading-left {
  font-size: 1.11rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: var(--space-sm);
  text-align: left;
}

.contact-content-left {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.contact-intro-left {
  color: var(--text);
  font-size: 1.01rem;
  margin-bottom: var(--space-md);
  font-weight: 500;
  text-align: left;
  max-width: 400px;
  line-height: 1.35;
}

.contact-info-list-left {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.contact-info-list-left li {
  display: flex;
  align-items: center;
  padding: var(--space-xs);
  background: white;
  border-radius: 7px;
  box-shadow: 0 2px 8px 0 rgba(24, 70, 163, 0.03);
}

.contact-label-left {
  font-weight: 700;
  color: var(--primary);
  margin-right: var(--space-xs);
  min-width: 40px;
  font-size: 1.01rem;
}

.contact-link-left {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: color 0.2s ease;
  font-size: 1.01rem;
}

.contact-link-left:hover {
  color: var(--accent-green);
  text-decoration: underline;
}

/* --- Quick Apply Floating Button --- */
.quick-apply-float-btn {
  position: fixed;
  right: 22px;
  bottom: 40px;
  z-index: 2001;
  background: var(--accent-green);
  color: #fff;
  border-radius: 100px;
  padding: 13px 26px;
  font-size: 1.05rem;
  font-weight: 700;
  box-shadow: 0 6px 24px 0 rgba(24, 70, 163, 0.22);
  border: none;
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s;
}
.quick-apply-float-btn:hover {
  background: var(--primary-light);
  color: #fff;
  box-shadow: 0 12px 32px 0 rgba(24, 70, 163, 0.18);
}

/* Hide the old Quick Apply box */
.quick-apply-card {
  display: none !important;
}

/* --- Modal Styles --- */
.quick-apply-modal-bg {
  display: none;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: rgba(24, 70, 163, 0.2);
  backdrop-filter: blur(4px);
  z-index: 9999;
  justify-content: center;
  align-items: center;
  padding: var(--space-md);
}

.quick-apply-modal-bg.active {
  display: flex;
}

.quick-apply-modal-content {
  background: white;
  border-radius: 10px;
  box-shadow: 0 12px 38px rgba(24, 70, 163, 0.17);
  padding: var(--space-md);
  width: 100%;
  max-width: 320px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.quick-apply-modal-close {
  position: absolute;
  right: var(--space-sm);
  top: var(--space-sm);
  font-size: 1.1rem;
  color: var(--text-muted);
  cursor: pointer;
  background: none;
  border: none;
  font-weight: 700;
  transition: color 0.2s ease;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quick-apply-modal-close:hover {
  color: var(--primary);
}

/* --- Forms --- */
label {
  display: block;
  margin-bottom: var(--space-xs);
  font-weight: 600;
  color: var(--primary);
  font-size: 1.01rem;
}

input,
select,
textarea {
  width: 100%;
  padding: 9px var(--space-sm);
  border-radius: 7px;
  border: 1px solid var(--border);
  background: var(--background);
  color: var(--text);
  font-size: 1.01rem;
  margin-bottom: var(--space-xs);
  outline: none;
  font-family: inherit;
  transition: all 0.2s ease;
  min-height: 32px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(24, 70, 163, 0.08);
}

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

input[type="file"] {
  background: var(--surface-dark);
  border: 2px dashed var(--border);
  padding: var(--space-md);
  text-align: center;
  cursor: pointer;
  font-size: 1.01rem;
}

input[type="file"]:hover {
  border-color: var(--primary);
  background: var(--surface);
}

/* --- Footer --- */
.site-footer {
  width: 100%;
  background: #000 !important;
  color: white;
  margin-top: var(--space-xl);
  position: relative;
  z-index: 1;
  font-size: 1rem;
  overflow: hidden;
}

.footer-flex {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--space-lg);
  padding: var(--space-lg) 0;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
}

.footer-brand .logo {
  width: 24px;
  height: 24px;
}

.footer-company-name {
  font-weight: 700;
  font-size: 1.05rem;
  color: white;
  line-height: 1.1;
}

.footer-slogan {
  font-size: 0.89rem;
  color: var(--accent-green);
  font-weight: 500;
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
  width: 100%;
}

.footer-section-title {
  font-size: 0.97rem;
  font-weight: 600;
  color: var(--accent-orange);
  margin-bottom: var(--space-md);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.footer-nav a {
  font-size: 0.97rem;
  padding: 0;
}

.footer-bottom {
  width: 100%;
  text-align: center !important;
  margin: 0 auto;
  padding: 10px 0 4px 0;
  color: #fff;
  font-size: .95rem;
}

/* --- Accessibility and Performance --- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus styles for accessibility */
.btn:focus,
input:focus,
select:focus,
textarea:focus,
a:focus {
  outline: 2px solid var(--accent-green);
  outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  :root {
    --border: #000;
    --text-muted: #000;
  }
}

/* --- Print styles --- */
@media print {
  .site-header,
  .quick-apply-float-btn,
  .quick-apply-modal-bg {
    display: none;
  }

  .hero,
  .stats-section,
  .contact-left-extreme {
    break-inside: avoid;
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .container {
    padding: 0 var(--space-sm);
    max-width: 100%;
    width: 100%;
  }
  .hero, .stats-section, .footer-flex, .contact-left-extreme {
    padding: var(--space-sm);
  }
  .quick-apply-float-btn {
    right: 10px;
    bottom: 10px;
    font-size: 1rem;
    padding: 10px 15px;
  }
  .quick-apply-modal-content {
    max-width: 95vw;
  }
  .back-btn, .btn.ghost.back-float {
    left: 1rem;
    top: 70px !important;
    font-size: 0.97rem;
    padding: 0.6rem 1.1rem;
  }

  /* --- Fix: Header Nav stays horizontal, logo/text scale down --- */
  .site-header nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-end;
  }
  .site-header nav a,
  .site-header nav .btn {
    font-size: 1rem;
    padding: 8px 12px;
    max-width: 100vw;
    white-space: nowrap;
    word-break: normal;
    box-sizing: border-box;
  }
  .site-header .brand {
    font-size: 1.1rem;
    gap: 8px;
    margin-right: 10px;
  }
  .site-header .logo {
    width: 32px;
    height: 32px;
    border-radius: 7px;
  }
  .hero {
    margin-top: 50px; /* INCREASED spacing below header for mobile */
    padding-top: var(--space-xl); /* More padding above hero content */
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    min-height: 180px;
  }

  .hero-title {
    font-size: 2.1rem;
  }
  .section-title {
    font-size: 1.6rem;
  }
}

@media (max-width: 480px) {
  .footer-flex {
    grid-template-columns: 1fr;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-xs);
    max-width: 100vw;
  }
  .back-btn, .btn.ghost.back-float {
    left: 0.5rem;
    top: 66px !important;
    font-size: 0.95rem;
    padding: 0.45rem 0.9rem;
  }

  .site-header nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-end;
  }
  .site-header nav a,
  .site-header nav .btn {
    font-size: 0.97rem;
    padding: 8px 10px;
    max-width: 100vw;
    white-space: nowrap;
    word-break: normal;
    box-sizing: border-box;
  }
  .site-header .brand {
    font-size: 0.9rem;
    gap: 5px;
    margin-right: 6px;
  }
  .site-header .logo {
    width: 22px;
    height: 22px;
    border-radius: 5px;
  }
  .hero {
    margin-top: 50px;
    padding-top: var(--space-xl);
    grid-template-columns: 1fr;
    gap: var(--space-md);
    min-height: 120px;
  }

  .hero-title {
    font-size: 2rem;
  }
  .section-title {
    font-size: 1.4rem;
  }
}