/*
 Theme Name: Astra Luxury Child V2
 Theme URI: https://rajaampatislands.com
 Description: Premium luxury child theme for Raja Ampat Islands - $10M standard tourism website
 Author: Bali Juara Team
 Author URI: https://rajaampatislands.com
 Template: astra
 Version: 2.0.0
 License: GNU General Public License v2 or later
 License URI: https://www.gnu.org/licenses/gpl-2.0.html
 Text Domain: astra-luxury-child-v2
*/

/* ============================================
   1. DESIGN TOKENS — Brand Colors & Variables
   ============================================ */
:root {
  /* Brand Colors — Raja Ampat Ocean Luxury */
  --brand-navy: #0A1628;
  --brand-gold: #C8A55C;
  --brand-teal: #0D7377;
  --brand-white: #FAFAF8;
  --brand-warm-bg: #F5F1EB;
  --brand-card-dark: #111E30;

  /* Extended Palette */
  --brand-navy-light: #162A4A;
  --brand-gold-light: #E8D5A0;
  --brand-teal-light: #14A3A8;
  --brand-teal-dark: #095456;
  --brand-coral: #E8734A;
  --brand-ocean: #1B6B93;

  /* Semantic Colors */
  --color-text-primary: var(--brand-white);
  --color-text-body: rgba(250,250,248,0.85);
  --color-text-muted: rgba(250,250,248,0.6);
  --color-text-dark: #1a1a2e;
  --color-text-dark-body: #444;
  --color-bg-primary: var(--brand-navy);
  --color-bg-secondary: var(--brand-warm-bg);
  --color-bg-card: var(--brand-card-dark);
  --color-accent: var(--brand-gold);
  --color-accent-hover: #B8953C;
  --color-cta: var(--brand-teal);
  --color-cta-hover: var(--brand-teal-light);

  /* Typography */
  --font-heading: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-accent: 'Cormorant Garamond', Georgia, serif;

  /* Font Sizes — Fluid Typography */
  --fs-hero: clamp(2.5rem, 5vw, 4.5rem);
  --fs-h1: clamp(2rem, 4vw, 3.5rem);
  --fs-h2: clamp(1.75rem, 3vw, 2.75rem);
  --fs-h3: clamp(1.25rem, 2vw, 1.75rem);
  --fs-h4: clamp(1.1rem, 1.5vw, 1.35rem);
  --fs-body: clamp(1rem, 1.2vw, 1.125rem);
  --fs-small: 0.875rem;
  --fs-label: 0.75rem;

  /* Spacing Scale */
  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 24px;
  --space-lg: 48px;
  --space-xl: 80px;
  --space-2xl: 120px;

  /* Layout */
  --max-width: 1200px;
  --max-width-wide: 1400px;
  --border-radius: 16px;
  --border-radius-sm: 8px;
  --border-radius-lg: 24px;

  /* Shadows */
  --shadow-card: 0 4px 24px rgba(0,0,0,0.12);
  --shadow-card-hover: 0 8px 40px rgba(0,0,0,0.2);
  --shadow-hero: 0 20px 60px rgba(0,0,0,0.3);

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* ============================================
   2. GOOGLE FONTS IMPORT
   ============================================ */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400;1,500;1,600&family=Inter:wght@300;400;500;600;700&family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400;1,500&display=swap');

/* ============================================
   3. GLOBAL RESETS & BASE TYPOGRAPHY
   ============================================ */
body {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.7;
  color: var(--color-text-dark-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.entry-content h2 {
  font-size: var(--fs-h2);
  margin: var(--space-lg) 0 var(--space-md);
  color: var(--brand-navy);
}

.entry-content h3 {
  font-size: var(--fs-h3);
  margin: var(--space-md) 0 var(--space-sm);
  color: var(--brand-navy);
}

.entry-content h4 {
  font-size: var(--fs-h4);
  margin: var(--space-sm) 0 var(--space-xs);
  color: var(--brand-navy);
}

.entry-content p {
  margin-bottom: var(--space-sm);
  line-height: 1.8;
}

/* ============================================
   4. RESPONSIVE GRID SYSTEM
   ============================================ */
/* DUAL attribute selector pattern — handles both spacing variants */
[style*="grid-template-columns: repeat(3"],
[style*="grid-template-columns:repeat(3"] {
  display: grid !important;
  gap: 24px;
}

[style*="grid-template-columns: repeat(2"],
[style*="grid-template-columns:repeat(2"] {
  display: grid !important;
  gap: 24px;
}

[style*="grid-template-columns: repeat(4"],
[style*="grid-template-columns:repeat(4"] {
  display: grid !important;
  gap: 24px;
}

/* Mobile grid collapse */
@media (max-width: 768px) {
  [style*="grid-template-columns: repeat(3"],
  [style*="grid-template-columns:repeat(3"],
  [style*="grid-template-columns: repeat(4"],
  [style*="grid-template-columns:repeat(4"] {
    grid-template-columns: 1fr !important;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  [style*="grid-template-columns: repeat(3"],
  [style*="grid-template-columns:repeat(3"],
  [style*="grid-template-columns: repeat(4"],
  [style*="grid-template-columns:repeat(4"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* ============================================
   5. COMPONENT STYLES — Cards
   ============================================ */
.db-service-card,
[style*="background: #111E30"][style*="border-radius: 16px"],
[style*="background:#111E30"][style*="border-radius:16px"] {
  background: var(--brand-card-dark) !important;
  border-radius: var(--border-radius) !important;
  padding: var(--space-md) !important;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  overflow: hidden;
}

.db-service-card:hover,
[style*="background: #111E30"][style*="border-radius: 16px"]:hover,
[style*="background:#111E30"][style*="border-radius:16px"]:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
}

/* ============================================
   6. COMPONENT STYLES — Buttons & CTAs
   ============================================ */
.db-cta-button,
a.db-cta-button {
  display: inline-block;
  background: var(--brand-teal);
  color: var(--brand-white) !important;
  padding: 16px 40px;
  border-radius: 50px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none !important;
  text-align: center;
  transition: all var(--transition-base);
  cursor: pointer;
  letter-spacing: 0.02em;
  min-width: 200px;
  border: none;
}

.db-cta-button:hover,
a.db-cta-button:hover {
  background: var(--brand-teal-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(13,115,119,0.3);
}

.db-cta-secondary,
a.db-cta-secondary {
  display: inline-block;
  background: transparent;
  color: var(--brand-gold) !important;
  padding: 14px 36px;
  border: 2px solid var(--brand-gold);
  border-radius: 50px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none !important;
  transition: all var(--transition-base);
}

.db-cta-secondary:hover,
a.db-cta-secondary:hover {
  background: var(--brand-gold);
  color: var(--brand-navy) !important;
}

/* ============================================
   7. COMPONENT STYLES — Hero Section
   ============================================ */
.db-hero-section {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  margin: 0 !important;
  padding: var(--space-xl) var(--space-md);
}

.db-hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10,22,40,0.7) 0%, rgba(10,22,40,0.4) 50%, rgba(10,22,40,0.8) 100%);
  z-index: 1;
}

.db-hero-section > * {
  position: relative;
  z-index: 2;
}

.db-hero-section h1 {
  font-size: var(--fs-hero);
  color: var(--brand-white);
  margin-bottom: var(--space-md);
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.db-hero-section p {
  font-size: clamp(1.1rem, 1.5vw, 1.35rem);
  color: rgba(250,250,248,0.9);
  max-width: 700px;
  margin: 0 auto var(--space-md);
}

/* ============================================
   8. COMPONENT STYLES — AEO Atomic Answer
   ============================================ */
.aeo-atomic-answer {
  border-left: 4px solid var(--brand-gold);
  padding: var(--space-md) var(--space-md);
  background: var(--brand-warm-bg);
  border-radius: 0 var(--border-radius-sm) var(--border-radius-sm) 0;
  margin: var(--space-md) 0;
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--color-text-dark);
}

.aeo-atomic-answer strong {
  color: var(--brand-navy);
}

/* ============================================
   9. COMPONENT STYLES — Content Images
   ============================================ */
figure.db-content-image {
  margin: var(--space-md) 0;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

figure.db-content-image img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

figure.db-content-image figcaption {
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  background: var(--brand-card-dark);
  text-align: center;
}

/* ============================================
   10. COMPONENT STYLES — FAQ Section
   ============================================ */
.entry-content h3 + p {
  padding-left: var(--space-sm);
  border-left: 3px solid var(--brand-teal);
  margin-bottom: var(--space-md);
}

/* ============================================
   11. COMPONENT STYLES — Section Patterns
   ============================================ */
section[style*="background"] {
  padding: var(--space-xl) var(--space-md);
}

section[style*="background"] h2 {
  text-align: center;
  margin-bottom: var(--space-lg);
}

/* Dark sections */
section[style*="background: #0A1628"] h2,
section[style*="background:#0A1628"] h2 {
  color: var(--brand-white) !important;
}

section[style*="background: #0A1628"] p,
section[style*="background:#0A1628"] p {
  color: var(--color-text-body) !important;
}

/* Warm BG sections */
section[style*="background: #F5F1EB"] h2,
section[style*="background:#F5F1EB"] h2 {
  color: var(--brand-navy) !important;
}

/* ============================================
   12. COMPONENT STYLES — Trust Signals / Stats
   ============================================ */
.db-stat-number {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  font-weight: 700;
  color: var(--brand-gold);
  line-height: 1;
  margin-bottom: var(--space-xs);
}

.db-stat-label {
  font-family: var(--font-body);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

/* ============================================
   13. COMPONENT STYLES — Footer
   ============================================ */
.site-footer {
  background: var(--brand-navy) !important;
  color: var(--color-text-body);
}

.site-footer a {
  color: var(--brand-gold) !important;
  text-decoration: none;
  transition: color var(--transition-fast);
}

.site-footer a:hover {
  color: var(--brand-gold-light) !important;
}

/* ============================================
   14. COMPONENT STYLES — Navigation
   ============================================ */
.main-header-bar {
  background: rgba(10,22,40,0.95) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(200,165,92,0.15);
}

.main-navigation a {
  color: var(--brand-white) !important;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: color var(--transition-fast);
}

.main-navigation a:hover,
.main-navigation .current-menu-item > a {
  color: var(--brand-gold) !important;
}

/* Dropdown menus */
.main-navigation .sub-menu {
  background: var(--brand-navy) !important;
  border: 1px solid rgba(200,165,92,0.15);
  border-radius: var(--border-radius-sm);
  box-shadow: var(--shadow-card);
}

.main-navigation .sub-menu a {
  padding: 10px 20px !important;
}

.main-navigation .sub-menu a:hover {
  background: var(--brand-navy-light) !important;
}

/* Site Title/Logo */
.site-title a,
.ast-site-title-wrap a {
  color: var(--brand-white) !important;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.4rem;
}

/* ============================================
   15. SCROLL ANIMATIONS
   ============================================ */
.db-fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.db-fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   16. MOBILE RESPONSIVE OVERRIDES
   ============================================ */
@media (max-width: 768px) {
  .db-hero-section {
    min-height: 70vh;
    padding: var(--space-lg) var(--space-sm);
  }

  .db-hero-section h1 {
    font-size: clamp(1.75rem, 7vw, 2.5rem);
  }

  .db-cta-button,
  a.db-cta-button {
    width: 100%;
    padding: 16px 24px;
    min-width: unset;
  }

  section[style*="background"] {
    padding: var(--space-lg) var(--space-sm);
  }

  .aeo-atomic-answer {
    padding: var(--space-sm);
  }

  /* Touch targets */
  .db-cta-button,
  .main-navigation a,
  .sub-menu a {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  :root {
    --space-lg: 32px;
    --space-xl: 48px;
  }
}

/* ============================================
   17. UTILITY CLASSES
   ============================================ */
.text-center { text-align: center; }
.text-gold { color: var(--brand-gold) !important; }
.text-white { color: var(--brand-white) !important; }
.text-navy { color: var(--brand-navy) !important; }
.bg-navy { background: var(--brand-navy); }
.bg-warm { background: var(--brand-warm-bg); }
.bg-card-dark { background: var(--brand-card-dark); }
.container-narrow { max-width: 800px; margin: 0 auto; }

/* ============================================
   18. PRINT STYLES
   ============================================ */
@media print {
  .db-hero-section { min-height: auto; }
  .db-cta-button { display: none; }
  nav, .site-footer { display: none; }
}
