:root {
  --blue:        hsl(214, 68%, 32%);
  --blue-light:  hsl(214, 57%, 51%);
  --blue-dark:   hsl(214, 72%, 18%);
  --gold:        hsl(40, 56%, 54%);
  --black-coral: hsl(225, 8%, 42%);
  --gunmetal:    hsl(206, 34%, 20%);
  --gainsboro:   hsl(0, 0%, 88%);
  --cultured:    hsl(0, 0%, 97%);
  --white:       hsl(0, 0%, 100%);
  --onyx:        hsl(0, 0%, 25%);
  --jet:         hsl(0, 0%, 20%);

  --ff-poppins:    "Poppins", sans-serif;
  --ff-montserrat: "Montserrat", sans-serif;

  --fs-1: calc(22px + 3.5vw);
  --fs-2: calc(18px + 1.6vw);
  --fs-3: calc(16px + 0.45vw);
  --fs-4: 15px;
  --fs-5: 14px;
  --fs-6: 13px;
  --fs-7: 12px;
  --fs-8: 11px;

  --fw-500: 500;
  --fw-600: 600;
  --fw-700: 700;
  --fw-800: 800;

  --transition: 0.25s ease-in-out;
  --section-padding: 60px;
  --radius-15: 15px;
  --radius-25: 25px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
li { list-style: none; }
a { text-decoration: none; }
a, img, span, input, label, button, ion-icon { display: block; }
input, button { background: none; border: none; font: inherit; }
button { cursor: pointer; }
input { width: 100%; }
ion-icon { pointer-events: none; }
html { font-family: var(--ff-poppins); scroll-behavior: smooth; }
body { background: var(--white); }

.container { padding-inline: 15px; }

.btn {
  color: var(--white);
  text-transform: uppercase;
  font-size: var(--fs-5);
  border-radius: 100px;
  padding: var(--padding, 8px 18px);
  border: var(--border-width, 2px) solid transparent;
  transition: var(--transition);
}
.btn-primary { background: var(--blue); border-color: var(--blue); }
.btn-primary:is(:hover, :focus) { background: var(--blue-dark); border-color: var(--blue-dark); }
.btn-secondary { border-color: var(--white); }
.btn-secondary:is(:hover, :focus) { background: hsla(0, 0%, 100%, 0.1); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--white); }
.btn-gold:is(:hover, :focus) { background: hsl(40, 56%, 44%); border-color: hsl(40, 56%, 44%); }

.h1, .h2, .h3 { font-weight: var(--fw-800); font-family: var(--ff-montserrat); text-transform: uppercase; }
.h1 { color: var(--white); font-size: var(--fs-1); }
.h2, .h3 { color: var(--gunmetal); }
.h2 { font-size: var(--fs-2); }
.h3 { font-size: var(--fs-3); font-weight: var(--fw-700); }

.section-subtitle {
  color: var(--blue);
  font-size: var(--fs-5);
  text-transform: uppercase;
  font-family: var(--ff-montserrat);
  margin-bottom: 8px;
}
.section-title { margin-bottom: 15px; }
.section-text { color: var(--black-coral); margin-bottom: 30px; }
.card-text { color: var(--black-coral); font-size: var(--fs-5); }

/* ── HEADER ── */
.header {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  z-index: 4;
}

.app-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--white);
  font-family: var(--ff-montserrat);
  font-weight: var(--fw-800);
  font-size: 17px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}
.app-logo img {
  width: 34px; height: 34px;
  border-radius: 8px;
  object-fit: cover;
}

.header-bottom { border-bottom: 1px solid hsla(0, 0%, 100%, 0.1); }
.header-bottom .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-block: 18px;
}

.header .navbar {
  position: fixed;
  top: 0; right: -300px;
  width: 100%; max-width: 300px;
  height: 100%;
  background: var(--white);
  visibility: hidden;
  pointer-events: none;
  transition: 0.15s ease-in;
  z-index: 3;
}
.navbar.active { right: 0; visibility: visible; pointer-events: all; transition: 0.25s ease-out; }
.navbar-top { display: flex; justify-content: space-between; align-items: center; padding: 40px 15px; }
.nav-close-btn { font-size: 20px; color: var(--blue); }
.nav-close-btn ion-icon { --ionicon-stroke-width: 80px; }
.navbar-list { border-top: 1px solid hsla(0, 0%, 0%, 0.1); }
.navbar-list li { border-bottom: 1px solid hsla(0, 0%, 0%, 0.1); }
.navbar-link {
  padding: 15px 20px;
  color: var(--jet);
  font-weight: var(--fw-500);
  font-size: var(--fs-4);
  transition: var(--transition);
  text-transform: capitalize;
}
.navbar-link:is(:hover, :focus) { color: var(--blue); }

.overlay {
  position: fixed; inset: 0;
  background: var(--jet);
  opacity: 0; pointer-events: none;
  z-index: 2;
  transition: var(--transition);
}
.overlay.active { opacity: 0.7; pointer-events: all; }

.header-btn-group { display: flex; align-items: center; gap: 10px; color: var(--white); }
.nav-open-btn { font-size: 30px; color: inherit; }

/* ── HERO ── */
.hero {
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  background-color: var(--blue-dark);
  background-blend-mode: overlay;
  display: grid;
  place-items: center;
  min-height: 600px;
  text-align: center;
  padding-top: 90px;
  transition: background-image 1s ease;
}
.hero-title { margin-bottom: 20px; }
.hero-text { color: var(--white); font-size: var(--fs-5); margin-bottom: 40px; opacity: 0.9; }
.btn-group { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 10px; }

.app-store-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--white);
  color: var(--blue);
  padding: 12px 28px;
  border-radius: 100px;
  font-weight: var(--fw-700);
  font-size: var(--fs-5);
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s, box-shadow 0.2s;
  text-transform: none;
  letter-spacing: 0;
}
.app-store-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(0, 0, 0, 0.25); }
.app-store-btn svg { width: 20px; height: 20px; flex-shrink: 0; }

/* ── POPULAR / PLACES ── */
.popular { padding-block: var(--section-padding); }
.popular-list, .popular-list > li:not(:last-child) { margin-bottom: 30px; }

.popular-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-25);
  height: 430px;
  display: block;
  transition: transform 0.25s var(--transition), box-shadow 0.25s var(--transition);
  background: var(--gunmetal);
}
.popular-card .card-img {
  height: 100%;
  overflow: hidden;
  border-radius: var(--radius-25);
}
.popular-card .card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transform: scale(1);
  transition: transform 0.6s cubic-bezier(0.2, 0.6, 0.2, 1);
  will-change: transform;
  opacity: 0;
  transition: transform 0.6s cubic-bezier(0.2, 0.6, 0.2, 1), opacity 0.5s ease;
}
.popular-card .card-img img.loaded { opacity: 1; }
.popular-card:hover .card-img img,
.popular-card:focus-visible .card-img img { transform: scale(1.08); }
.popular-card:hover,
.popular-card:focus-visible { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12); }

.popular-card .card-content {
  position: absolute;
  bottom: 20px; left: 20px; right: 20px;
  background: var(--white);
  border-radius: var(--radius-25);
  padding: 20px;
}
.popular-card .card-rating {
  background: var(--blue);
  color: var(--white);
  position: absolute;
  top: 0; right: 25px;
  display: flex;
  align-items: center;
  gap: 3px;
  transform: translateY(-50%);
  padding: 6px 10px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: var(--fw-600);
}
.star-icon { font-size: 12px; }
.popular-card .card-subtitle {
  color: var(--blue-light);
  font-size: var(--fs-6);
  text-transform: uppercase;
  margin-bottom: 8px;
  font-family: var(--ff-montserrat);
  font-weight: var(--fw-600);
}
.popular-card .card-title { margin-bottom: 5px; }
.popular-card .card-title span { color: var(--gunmetal); }

.date-badge {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--blue);
  color: var(--white);
  font-size: var(--fs-7);
  font-family: var(--ff-montserrat);
  padding: 6px 12px;
  border-radius: 999px;
  letter-spacing: 0.4px;
  opacity: 0.95;
}

.hidden-gem-badge {
  position: absolute;
  top: 12px; right: 12px;
  background: linear-gradient(135deg, #7C3AED, #5B21B6);
  color: var(--white);
  font-size: var(--fs-7);
  font-family: var(--ff-montserrat);
  padding: 6px 12px;
  border-radius: 999px;
  letter-spacing: 0.4px;
}

/* skeleton loader for cards */
.skeleton-card {
  border-radius: var(--radius-25);
  height: 430px;
  background: linear-gradient(90deg, #e8e8e8 25%, #f5f5f5 50%, #e8e8e8 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.popular .btn { margin-inline: auto; }

/* ── GEMS SECTION (blurred teaser) ── */
.gems-section { padding-block: var(--section-padding); background: var(--cultured); }
.gems-grid { display: grid; gap: 20px; }
.gem-card {
  position: relative;
  border-radius: var(--radius-15);
  overflow: hidden;
  height: 280px;
}
.gem-card img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: blur(6px) brightness(0.6);
  transform: scale(1.05);
}
.gem-lock {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--white);
  text-align: center;
  padding: 20px;
}
.gem-lock .lock-icon { font-size: 36px; margin-bottom: 10px; }
.gem-lock h3 {
  font-family: var(--ff-montserrat);
  font-size: var(--fs-3);
  font-weight: var(--fw-800);
  text-transform: uppercase;
  margin-bottom: 6px;
  color: var(--white);
}
.gem-lock p { font-size: var(--fs-6); opacity: 0.85; }

/* ── CAR RENTAL ── */
.car-rental { background: var(--cultured); padding-block: var(--section-padding); }

/* Card — same pattern as .popular-card */
.rental-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-25);
  height: 520px;
  display: block;
  background: var(--gunmetal);
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  cursor: pointer;
  text-decoration: none;
}
.rental-card:hover { transform: translateY(-3px); box-shadow: 0 14px 40px rgba(0,0,0,0.18); }
.rental-card .card-img { height: 100%; overflow: hidden; border-radius: var(--radius-25); }
.rental-card .card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Top badge */
.rental-top-badge {
  position: absolute;
  top: 16px; left: 16px;
  background: var(--gold);
  color: var(--white);
  font-size: 13px;
  font-family: var(--ff-montserrat);
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 999px;
  letter-spacing: 0.3px;
}

/* Bottom content — same as .popular-card .card-content */
.rental-card-content {
  position: absolute;
  bottom: 20px; left: 20px; right: 20px;
  background: var(--white);
  border-radius: var(--radius-25);
  padding: 20px 22px 22px;
}
/* Carla logo badge — floats above content like rating badge */
.rental-card-rating {
  position: absolute;
  top: 0; right: 25px;
  transform: translateY(-50%);
  background: var(--white);
  border-radius: 20px;
  padding: 6px 14px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.carla-logo-card { height: 20px; width: auto; display: block; }

.rental-card-label {
  color: var(--blue);
  font-size: 11px;
  font-family: var(--ff-montserrat);
  font-weight: 700;
  letter-spacing: 0.6px;
  margin-bottom: 6px;
}
.rental-card-title {
  font-size: var(--fs-4);
  font-family: var(--ff-montserrat);
  font-weight: 700;
  color: var(--gunmetal);
  margin-bottom: 14px;
  line-height: 1.3;
}

.rental-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.rental-badge {
  background: var(--cultured);
  border-radius: 10px;
  padding: 7px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--onyx);
  font-size: var(--fs-6);
}
.rental-badge span:first-child { font-size: 15px; }

.rental-inline-btn {
  display: inline-block;
  padding: 11px 28px;
  font-size: 14px;
  text-transform: none;
  font-weight: 700;
  letter-spacing: 0;
}

/* ── FEATURES ── */
.features-section { padding-block: var(--section-padding); }
.features-grid {
  display: grid;
  gap: 20px;
}
.feature-card {
  background: var(--cultured);
  border-radius: var(--radius-15);
  padding: 24px;
  border: 1px solid hsla(0, 0%, 0%, 0.05);
}
.feature-icon { font-size: 32px; margin-bottom: 12px; }
.feature-card h3 {
  font-size: 16px;
  font-weight: var(--fw-700);
  font-family: var(--ff-montserrat);
  color: var(--gunmetal);
  margin-bottom: 8px;
  text-transform: uppercase;
}
.feature-card p { font-size: var(--fs-5); color: var(--black-coral); line-height: 1.6; }

/* ── GALLERY ── */
.gallery { padding-block: var(--section-padding); background: var(--cultured); }
.gallery-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.gallery-image {
  width: 100%; height: 100%;
  border-radius: var(--radius-15);
  overflow: hidden;
}
.gallery-item:nth-child(3) { grid-area: 1 / 2 / 3 / 3; }
.gallery-image img {
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.gallery-image img.loaded { opacity: 1; }

/* ── CTA ── */
.cta { background: var(--blue); padding-block: var(--section-padding); }
.cta :is(.section-subtitle, .section-title, .section-text) { color: var(--white); }
.cta .section-text { font-size: var(--fs-5); opacity: 0.85; }

/* ── FOOTER ── */
.footer-top {
  background: var(--gunmetal);
  padding-block: var(--section-padding);
  color: var(--gainsboro);
}
.footer-brand { margin-bottom: 30px; }
.footer-brand .logo-text {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--ff-montserrat);
  font-weight: var(--fw-800);
  text-transform: uppercase;
  font-size: 18px;
  color: var(--gainsboro);
  margin-bottom: 15px;
}
.footer-brand .logo-text img { width: 32px; height: 32px; border-radius: 7px; object-fit: cover; }
.footer-brand .logo-text:hover { color: var(--white); }
.footer-text { font-size: var(--fs-5); line-height: 1.7; }

.footer-links h4 {
  position: relative;
  font-family: var(--ff-montserrat);
  font-weight: var(--fw-600);
  margin-bottom: 30px;
  color: var(--gainsboro);
}
.footer-links h4::after {
  content: "";
  position: absolute;
  bottom: -10px; left: 0;
  width: 40px; height: 2px;
  background: var(--blue-light);
}
.footer-links ul { display: flex; flex-direction: column; gap: 8px; }
.footer-links a {
  color: var(--gainsboro);
  font-size: var(--fs-5);
  transition: var(--transition);
}
.footer-links a:is(:hover, :focus) { color: var(--white); padding-left: 4px; }

.footer-contact { margin-bottom: 30px; }
.contact-title {
  position: relative;
  font-family: var(--ff-montserrat);
  font-weight: var(--fw-500);
  margin-bottom: 30px;
  color: var(--gainsboro);
}
.contact-title::after {
  content: "";
  position: absolute;
  bottom: -10px; left: 0;
  width: 50px; height: 2px;
  background: var(--blue-light);
}
.contact-item { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.contact-link { color: var(--gainsboro); font-size: var(--fs-5); transition: var(--transition); }
.contact-link:is(:hover, :focus) { color: var(--white); }

.footer-bottom {
  background: hsl(205, 36%, 17%);
  padding-block: 20px;
  text-align: center;
}
.copyright { color: var(--gainsboro); font-size: var(--fs-5); margin-bottom: 10px; }
.footer-bottom-list { display: flex; align-items: center; justify-content: center; gap: 21px; }
.footer-bottom-list > li { position: relative; }
.footer-bottom-list > li:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 3px; right: -10px;
  bottom: 3px; width: 1px;
  background: hsla(0, 0%, 100%, 0.2);
}
.footer-bottom-link { color: var(--gainsboro); font-size: var(--fs-7); transition: var(--transition); }
.footer-bottom-link:is(:hover, :focus) { color: var(--white); }

/* ── GO TO TOP ── */
.go-top {
  position: fixed;
  bottom: 15px; right: 15px;
  width: 35px; height: 35px;
  background: var(--blue);
  color: var(--white);
  display: grid; place-items: center;
  font-size: 18px;
  border-radius: 6px;
  box-shadow: 0 1px 3px hsla(0, 0%, 0%, 0.5);
  opacity: 0; transform: translateY(10px);
  visibility: hidden;
  transition: var(--transition);
}
.go-top.active { opacity: 0.8; transform: translateY(0); visibility: visible; }
.go-top:is(:hover, :focus) { opacity: 1; }

/* ── MEDIA QUERIES ── */
@media (min-width: 580px) {
  .container { max-width: 580px; margin-inline: auto; }
  .btn { --fs-5: 16px; --padding: 12px 30px; }
  section:not(.cta) :is(.section-subtitle, .section-title, .section-text) { text-align: center; }
  .section-text { margin-bottom: 40px; }

  .hero { min-height: 800px; }

  .gems-grid { grid-template-columns: 1fr 1fr; }
  .rental-card { height: 600px; }

  .gallery-image { border-radius: var(--radius-25); }
  .cta .container { display: flex; justify-content: space-between; align-items: center; }
  .cta-content { width: calc(100% - 220px); }

  .footer-top .container { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }
  .footer-bottom { text-align: left; }
  .copyright { margin-bottom: 0; }
  .footer-bottom-list { justify-content: flex-end; }
  .footer-bottom .container { display: flex; justify-content: space-between; align-items: center; }
}

@media (min-width: 768px) {
  :root { --fs-5: 15px; }
  .container { max-width: 800px; }
  .section-text { max-width: 60ch; margin-inline: auto; }

  .popular-list { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; margin-bottom: 50px; }
  .popular-list > li:not(:last-child) { margin-bottom: 0; }
  .popular-card .card-content { right: 20px; }

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

  .gallery-list { grid-template-columns: repeat(3, 1fr); gap: 20px; }
}

@media (min-width: 992px) {
  .container { max-width: 1050px; }
  .nav-open-btn, .navbar-top { display: none; }
  .header-bottom { border-bottom: none; }
  .header-bottom .container { padding-block: 0; }

  /* sticky bar po scrollu */
  .header.active .header-bottom {
    position: fixed; top: 0; left: 0; width: 100%;
    background: var(--white);
    box-shadow: 0 2px 8px hsla(0, 0%, 0%, 0.1);
  }
  .header.active .app-logo { color: var(--blue); }
  .header.active .navbar-link { color: var(--onyx); }
  .header.active .navbar-link:is(:hover, :focus) { color: var(--blue); }
  .header.active .header-btn-group { color: var(--onyx); }
  .overlay { display: none; }

  /* nav inline */
  .header .navbar { all: unset; }
  .navbar-list { border-top: none; display: flex; align-items: center; gap: 4px; }
  .navbar-list li { border-bottom: none; }
  .navbar-link {
    color: var(--white);
    font-size: 14px;
    font-weight: var(--fw-500);
    text-transform: uppercase;
    padding: 24px 12px;
    letter-spacing: 0.3px;
  }

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

  .rental-card { height: 680px; }

  .footer-top .container { grid-template-columns: 1fr 1fr; gap: 50px; }
}

@media (max-width: 991px) {
  .header-bottom { border-bottom: none; }
  .header-bottom .container { padding-block: 14px; }
  .header-btn-group { margin-left: auto; }
  .nav-open-btn { font-size: 28px; line-height: 1; }
}

@media (min-width: 1200px) {
  :root { --section-padding: 100px; }
  .container { max-width: 1180px; }
}

@media (prefers-reduced-motion: reduce) {
  .popular-card, .popular-card .card-img img { transition: none !important; }
}
