/* ============================================
   Igalo Apartments — Mediterranean Theme
   Clean, light, mobile-first
   ============================================ */

:root {
  --blue-deep: #1a3a5c;
  --blue-mid: #2c6faa;
  --blue-light: #4a9eda;
  --blue-sky: #e8f4fd;
  --blue-pale: #f0f7fc;
  --sand: #f5f0e8;
  --sand-dark: #d4c5a9;
  --white: #ffffff;
  --text: #2d3436;
  --text-light: #636e72;
  --accent: #e17055;
  --green: #00b894;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-hover: 0 8px 24px rgba(0,0,0,0.12);
  --radius: 12px;
  --max-width: 1200px;
  --transition: 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue-mid); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--blue-deep); }

h1, h2, h3, h4 { line-height: 1.3; color: var(--blue-deep); }
h1 { font-size: 2.5rem; font-weight: 700; }
h2 { font-size: 2rem; font-weight: 600; }
h3 { font-size: 1.4rem; font-weight: 600; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem; }

/* ========== HEADER / NAV ========== */
header {
  background: var(--white);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  background: rgba(255,255,255,0.95);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.logo {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--blue-deep);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo svg { width: 28px; height: 28px; }

nav ul {
  list-style: none;
  display: flex;
  gap: 2rem;
  align-items: center;
}

nav a {
  color: var(--text);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--blue-mid);
  transition: width var(--transition);
}

nav a:hover::after,
nav a.active::after { width: 100%; }
nav a.active { color: var(--blue-mid); }

.nav-cta {
  background: var(--blue-mid);
  color: var(--white) !important;
  padding: 0.5rem 1.2rem;
  border-radius: 8px;
  font-weight: 600;
}

.nav-cta:hover { background: var(--blue-deep); color: var(--white) !important; }
.nav-cta::after { display: none !important; }

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  margin: 5px 0;
  transition: var(--transition);
}

/* ========== HERO ========== */
.hero {
  background: linear-gradient(135deg, var(--blue-deep) 0%, var(--blue-mid) 100%);
  color: var(--white);
  padding: 5rem 1.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.5;
}

.hero > * { position: relative; z-index: 1; }

.hero h1 {
  color: var(--white);
  font-size: 3rem;
  margin-bottom: 1rem;
}

.hero p {
  font-size: 1.25rem;
  opacity: 0.9;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.hero-sub {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.hero-badge {
  background: rgba(255,255,255,0.15);
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  backdrop-filter: blur(4px);
}

/* ========== BUTTONS ========== */
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  text-align: center;
}

.btn-primary {
  background: var(--blue-mid);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--blue-deep);
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: var(--shadow-hover);
}

.btn-secondary {
  background: var(--white);
  color: var(--blue-mid);
  border: 2px solid var(--blue-mid);
}
.btn-secondary:hover {
  background: var(--blue-mid);
  color: var(--white);
}

.btn-book {
  background: var(--accent);
  color: var(--white);
}
.btn-book:hover {
  background: #d35400;
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: var(--shadow-hover);
}

.btn-sm { padding: 0.5rem 1rem; font-size: 0.9rem; }
.btn-lg { padding: 1rem 2rem; font-size: 1.1rem; }

/* ========== SECTIONS ========== */
section { padding: 4rem 0; }

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header p {
  color: var(--text-light);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0.75rem auto 0;
}

.bg-sand { background: var(--sand); }
.bg-blue { background: var(--blue-pale); }

/* ========== APARTMENT CARDS ========== */
.apartment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.apartment-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all var(--transition);
}

.apartment-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-4px);
}

.apartment-card-img {
  height: 200px;
  background: linear-gradient(135deg, var(--blue-sky) 0%, var(--sand) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--blue-mid);
  font-size: 3rem;
  position: relative;
}

.apartment-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.apartment-card-body {
  padding: 1.25rem;
}

.apartment-card-body h3 {
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

.apartment-card-meta {
  display: flex;
  gap: 1rem;
  margin-bottom: 0.75rem;
  font-size: 0.85rem;
  color: var(--text-light);
}

.apartment-card-meta span {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.apartment-card-features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.feature-tag {
  background: var(--blue-sky);
  color: var(--blue-mid);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
}

.apartment-card-body .btn {
  width: 100%;
  text-align: center;
}

/* ========== WHY SECTION ========== */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.why-card {
  text-align: center;
  padding: 2rem 1.5rem;
}

.why-card .icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.why-card h3 { margin-bottom: 0.75rem; }
.why-card p { color: var(--text-light); font-size: 0.95rem; }

/* ========== MAP ========== */
.map-section { padding: 4rem 0; }

.map-wrapper {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  height: 400px;
}

.map-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* ========== APARTMENT DETAIL ========== */
.detail-hero {
  background: linear-gradient(135deg, var(--blue-deep) 0%, var(--blue-mid) 100%);
  color: var(--white);
  padding: 3rem 1.5rem 2rem;
}

.detail-hero h1 { color: var(--white); font-size: 2.2rem; }
.detail-hero .breadcrumb { margin-bottom: 1rem; opacity: 0.8; font-size: 0.9rem; }
.detail-hero .breadcrumb a { color: rgba(255,255,255,0.8); }
.detail-hero .breadcrumb a:hover { color: var(--white); }

.detail-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2rem;
  padding: 2rem 0;
}

.detail-main { min-width: 0; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.gallery-grid .gallery-main {
  grid-column: span 3;
  height: 300px;
  background: linear-gradient(135deg, var(--blue-sky), var(--sand));
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--blue-mid);
  font-size: 1.1rem;
}

.gallery-grid .gallery-thumb {
  height: 100px;
  background: var(--blue-sky);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--blue-light);
  font-size: 0.85rem;
}

.detail-description { margin-bottom: 2rem; line-height: 1.8; }
.detail-description h2 { margin-bottom: 1rem; }
.detail-description p { margin-bottom: 1rem; color: var(--text-light); }

.amenities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.amenity-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: var(--blue-pale);
  border-radius: 8px;
  font-size: 0.9rem;
}

.amenity-item .amenity-icon { font-size: 1.1rem; }

/* Sidebar booking box */
.detail-sidebar { position: relative; }

.booking-box {
  background: var(--white);
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: var(--radius);
  padding: 1.5rem;
  position: sticky;
  top: 5rem;
  box-shadow: var(--shadow);
}

.booking-box h3 { margin-bottom: 1rem; font-size: 1.2rem; }

.booking-box .price {
  font-size: 1.1rem;
  color: var(--text-light);
  margin-bottom: 1.5rem;
}

.booking-box .btn { width: 100%; margin-bottom: 0.75rem; }

.booking-info {
  list-style: none;
  border-top: 1px solid rgba(0,0,0,0.06);
  padding-top: 1rem;
  margin-top: 0.5rem;
}

.booking-info li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0;
  font-size: 0.9rem;
  color: var(--text-light);
}

/* Nearby attractions */
.nearby-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.nearby-item {
  padding: 1rem;
  background: var(--blue-pale);
  border-radius: 8px;
}

.nearby-item h4 { font-size: 1rem; margin-bottom: 0.3rem; }
.nearby-item p { font-size: 0.85rem; color: var(--text-light); }
.nearby-item .distance { font-size: 0.8rem; color: var(--blue-mid); margin-top: 0.3rem; }

/* ========== AREA GUIDE ========== */
.guide-hero {
  background: linear-gradient(135deg, var(--blue-deep), var(--blue-mid));
  color: var(--white);
  padding: 4rem 1.5rem;
  text-align: center;
}

.guide-hero h1 { color: var(--white); }
.guide-hero p { opacity: 0.9; max-width: 600px; margin: 1rem auto 0; font-size: 1.15rem; }

.guide-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.guide-content h2 {
  margin: 2.5rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--blue-sky);
}

.guide-content p { margin-bottom: 1rem; color: var(--text-light); }
.guide-content ul { margin: 0 0 1.5rem 1.5rem; color: var(--text-light); }
.guide-content li { margin-bottom: 0.5rem; }

.info-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.info-card {
  background: var(--blue-pale);
  padding: 1.25rem;
  border-radius: var(--radius);
}

.info-card h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.info-card p { font-size: 0.9rem; margin: 0; }

.guide-cta {
  background: var(--sand);
  padding: 2rem;
  border-radius: var(--radius);
  text-align: center;
  margin: 2rem 0;
}

.guide-cta h3 { margin-bottom: 0.75rem; }
.guide-cta p { margin-bottom: 1rem; }

/* ========== CONTACT ========== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  padding: 3rem 0;
}

.contact-info h2 { margin-bottom: 1.5rem; }
.contact-info p { color: var(--text-light); margin-bottom: 1.5rem; }

.contact-method {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-method .icon {
  width: 48px;
  height: 48px;
  background: var(--blue-pale);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

.contact-method h3 { font-size: 1rem; margin-bottom: 0.2rem; }
.contact-method p { font-size: 0.9rem; margin: 0; }

.contact-form label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.3rem;
  font-size: 0.9rem;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(0,0,0,0.12);
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
  margin-bottom: 1rem;
  transition: border-color var(--transition);
  background: var(--white);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--blue-mid);
  box-shadow: 0 0 0 3px rgba(44,111,170,0.1);
}

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

/* ========== FOOTER ========== */
footer {
  background: var(--blue-deep);
  color: rgba(255,255,255,0.8);
  padding: 3rem 0 1.5rem;
}

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

.footer-brand p { font-size: 0.9rem; margin-top: 0.75rem; line-height: 1.6; }

.footer-col h4 {
  color: var(--white);
  margin-bottom: 1rem;
  font-size: 1rem;
}

.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 0.5rem; }
.footer-col a { color: rgba(255,255,255,0.7); font-size: 0.9rem; }
.footer-col a:hover { color: var(--white); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  opacity: 0.7;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }
  .hero h1 { font-size: 2.2rem; }
  .hero { padding: 3rem 1.5rem; }

  nav ul { display: none; }
  .nav-toggle { display: block; }

  nav.open ul {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    padding: 1rem 1.5rem;
    box-shadow: var(--shadow);
    gap: 0.5rem;
  }

  nav.open ul li { padding: 0.5rem 0; }

  .apartment-grid { grid-template-columns: 1fr; }
  .detail-content { grid-template-columns: 1fr; }
  .detail-sidebar { order: -1; }

  .booking-box { position: static; }

  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .gallery-grid .gallery-main { height: 200px; }

  .contact-grid { grid-template-columns: 1fr; }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }

  .footer-brand { grid-column: span 2; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 1.8rem; }
  section { padding: 2.5rem 0; }
  .hero-sub { flex-direction: column; align-items: center; }
  .gallery-grid .gallery-main { height: 160px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-brand { grid-column: span 1; }
}

/* ========== UTILITIES ========== */
.text-center { text-align: center; }
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
