/* ======================================================
   GoTrip – Madhukar's Sprint  |  Shared Base Styles
   US#10: Mobile-First Responsive Design
   ====================================================== */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Satisfy&display=swap');

/* ---------- CSS Variables ---------- */
:root {
  --primary: #ff5f6d;
  --secondary: #ffc371;
  --grad: linear-gradient(135deg, #ff5f6d, #ffc371);
  --dark: #1a1a2e;
  --dark2: #16213e;
  --light: #f8f9fa;
  --white: #ffffff;
  --text: #444;
  --text-light: #888;
  --shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  --radius: 12px;
  --transition: 0.3s ease;
  --nav-h: 70px;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', sans-serif;
  color: var(--text);
  background: var(--light);
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

/* ---------- Navigation ---------- */
.nav-bar {
  position: sticky;
  top: 0;
  z-index: 999;
  background: var(--dark);
  height: var(--nav-h);
  box-shadow: 0 2px 20px rgba(0, 0, 0, .3);
}

.nav-bar .container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: 'Satisfy', cursive;
  font-size: 1.8rem;
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-menu li a {
  color: #ccc;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 8px;
  transition: var(--transition);
}

.nav-menu li a:hover,
.nav-menu li a.active {
  background: var(--grad);
  color: #fff;
  -webkit-text-fill-color: #fff;
}

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
  background: none;
  border: none;
  padding: 6px;
  border-radius: 6px;
  transition: background .2s;
  z-index: 1001;
}

.hamburger:hover {
  background: rgba(255, 255, 255, .08);
}

.hamburger span {
  width: 26px;
  height: 3px;
  background: #fff;
  border-radius: 3px;
  transition: transform .35s ease, opacity .25s ease;
  display: block;
}

.hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 6px);
}

.hamburger.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -6px);
}

/* Mobile nav backdrop */
.nav-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .45);
  z-index: 997;
  opacity: 0;
  transition: opacity .3s ease;
}

.nav-backdrop.show {
  opacity: 1;
}

/* ---------- Page Hero ---------- */
.page-hero {
  background: var(--grad);
  padding: 80px 24px 60px;
  text-align: center;
  color: #fff;
}

.page-hero h1 {
  font-size: 2.6rem;
  font-weight: 700;
}

.page-hero p {
  font-size: 1.1rem;
  margin-top: 10px;
  opacity: .88;
}

/* ---------- Section ---------- */
.section {
  padding: 70px 24px;
}

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-header small {
  font-size: .85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-header h2 {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--dark);
  margin-top: 6px;
}

.section-header p {
  color: var(--text-light);
  margin-top: 8px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 50px;
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background: var(--grad);
  color: #fff;
  box-shadow: 0 4px 18px rgba(255, 95, 109, .35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(255, 95, 109, .45);
}

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

.btn-outline:hover {
  background: var(--grad);
  color: #fff;
  border-color: transparent;
}

/* ---------- Footer ---------- */
.footer {
  background: var(--dark2);
  color: #bbb;
  padding: 50px 24px 24px;
}

.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.footer h4 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 16px;
  position: relative;
  padding-bottom: 10px;
}

.footer h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 36px;
  height: 3px;
  background: var(--grad);
  border-radius: 2px;
}

.footer p {
  font-size: .88rem;
  line-height: 1.8;
}

.footer ul li {
  margin-bottom: 8px;
}

.footer ul li a {
  font-size: .88rem;
  color: #bbb;
  transition: var(--transition);
}

.footer ul li a:hover {
  color: var(--primary);
  padding-left: 4px;
}

.footer-bottom {
  max-width: 1200px;
  margin: 30px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  text-align: center;
  font-size: .82rem;
}

.social-links {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.social-links a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .08);
  display: grid;
  place-items: center;
  color: #ccc;
  font-size: .9rem;
  transition: var(--transition);
}

.social-links a:hover {
  background: var(--grad);
  color: #fff;
}

/* ---------- Back to Top ---------- */
.back-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 44px;
  height: 44px;
  background: var(--grad);
  color: #fff;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition);
  box-shadow: var(--shadow);
  z-index: 900;
}

.back-top.show {
  opacity: 1;
  pointer-events: all;
}

/* ---------- Alerts (inline messages) ---------- */
.alert {
  padding: 12px 18px;
  border-radius: var(--radius);
  font-size: .9rem;
  margin-bottom: 14px;
  font-weight: 500;
}

.alert-error {
  background: #ffe0e0;
  color: #c0392b;
  border-left: 4px solid #e74c3c;
}

.alert-success {
  background: #d5f5e3;
  color: #1e8449;
  border-left: 4px solid #2ecc71;
}

/* ======================================================
   US#10 – Responsive Media Queries
   ====================================================== */

/* Tablet */
@media (max-width: 900px) {
  .page-hero h1 {
    font-size: 2rem;
  }

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

/* Mobile */
@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--dark2);
    flex-direction: column;
    align-items: stretch;
    padding: 16px 0 24px;
    gap: 2px;
    transform: translateY(-110%);
    opacity: 0;
    transition: transform .35s ease, opacity .3s ease;
    box-shadow: 0 8px 32px rgba(0, 0, 0, .35);
    z-index: 998;
    border-top: 1px solid rgba(255, 255, 255, .06);
  }

  .nav-menu.open {
    transform: translateY(0);
    opacity: 1;
  }

  .nav-menu li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 28px;
    font-size: .95rem;
    border-radius: 0;
    border-left: 3px solid transparent;
    transition: background .2s, border-color .2s;
  }

  .nav-menu li a:hover,
  .nav-menu li a.active {
    background: rgba(255, 95, 109, .12);
    border-left-color: #ff5f6d;
    color: #fff;
    -webkit-text-fill-color: #fff;
  }

  .hamburger {
    display: flex;
  }

  .nav-backdrop {
    display: block;
  }

  .page-hero h1 {
    font-size: 1.7rem;
  }

  .page-hero p {
    font-size: 1rem;
  }

  .section {
    padding: 50px 16px;
  }

  .section-header h2 {
    font-size: 1.8rem;
  }
}

@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .page-hero {
    padding: 60px 16px 40px;
  }
}