/* ============================================================
   Llandudno Guide — Main Stylesheet
   Victorian seaside colour scheme
   ============================================================ */

/* Google Fonts loaded via <link> tags in HTML <head> */

/* ---- Variables ---- */
:root {
  --primary:       #0a3d6b;
  --primary-light: #1560a0;
  --primary-dark:  #062540;
  --accent:        #c8952a;
  --text:          #1a2a3a;
  --text-light:    #556070;
  --light-bg:      #f4f8fc;
  --border:        #d0dce8;
  --white:         #fff;
  --max-width:     1100px;
  --font-body:     'Open Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading:  'Merriweather', Georgia, serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: #dce8f0;
}

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

a { color: var(--primary); }
a:hover { color: var(--accent); }

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: 1.3;
  color: var(--primary-dark);
}

/* ---- Header & Navigation ---- */
#nav-placeholder { display: contents; }

.site-header {
  background: var(--primary);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
}

.site-title a {
  color: var(--white);
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.site-title a span { color: var(--accent); }

/* Nav */
.main-nav ul { list-style: none; display: flex; gap: 0; }
.main-nav li { position: relative; }

.main-nav a {
  display: block;
  color: var(--white);
  text-decoration: none;
  padding: 20px 9px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  transition: background 0.2s, color 0.2s;
  white-space: nowrap;
}

.main-nav a:hover,
.main-nav li.active > a {
  background: var(--primary-dark);
  color: var(--accent);
}

/* Dropdown */
.dropdown-menu {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--primary-dark);
  min-width: 210px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  z-index: 200;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.18s ease, visibility 0.18s ease, transform 0.18s ease;
  padding-top: 4px;
  margin-top: -4px;
}

.dropdown-menu li { width: 100%; }

.dropdown-menu a {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  font-size: 0.85rem;
}

.main-nav li:hover .dropdown-menu,
.main-nav li.open .dropdown-menu {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
}

/* Hamburger */
.nav-toggle {
  display: none;
  background: none;
  border: 2px solid rgba(255,255,255,0.5);
  color: var(--white);
  font-size: 1.3rem;
  padding: 5px 10px;
  border-radius: 4px;
  cursor: pointer;
}

/* ---- Hero (homepage) ---- */
.hero {
  position: relative;
  height: 580px;
  overflow: hidden;
  background-color: var(--primary-dark);
}

.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.7) 100%);
  z-index: 1;
}

.hero-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--white);
  padding: 20px;
  text-align: center;
}

.hero-content h1 {
  font-size: clamp(2.2rem, 6vw, 4rem);
  color: var(--white);
  text-shadow: 1px 2px 5px rgba(0,0,0,0.6);
  margin-bottom: 10px;
}

.hero-content p {
  font-size: clamp(0.95rem, 2.5vw, 1.15rem);
  text-shadow: 1px 1px 4px rgba(0,0,0,0.9);
}

.hero-content a { color: #ffe88a; text-decoration: none; }
.hero-content a:hover { text-decoration: underline; }

/* ---- Page Banner (inner pages) ---- */
.page-banner {
  background: var(--primary);
  color: var(--white);
  padding: 28px 20px;
  text-align: center;
}

.page-banner h1 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--white);
}

.page-banner p { opacity: 0.85; margin-top: 6px; }

/* ---- Main Content Wrapper ---- */
.content-wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  background: var(--white);
  box-shadow: 0 0 20px rgba(0,0,0,0.12);
}

/* ---- Content Sections ---- */
.section, .section-alt { padding: 40px 32px; }

.section + .section,
.section-alt + .section,
.section + .section-alt,
.section-alt + .section-alt { border-top: 1px solid var(--border); }

.section-alt { background: var(--light-bg); }

.section h2, .section-alt h2 {
  font-size: 1.5rem;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
}

.section h3, .section-alt h3 {
  font-size: 1.15rem;
  margin-bottom: 10px;
  color: var(--primary);
}

.section p, .section-alt p { margin-bottom: 20px; }
.section p:last-child, .section-alt p:last-child { margin-bottom: 0; }

/* ---- Section inner ---- */
.section-inner { max-width: 800px; }

/* ---- Image layouts ---- */
.img-float-right { float: right; margin: 0 0 16px 24px; max-width: 45%; }
.img-float-left  { float: left;  margin: 0 24px 16px 0; max-width: 45%; }
.img-caption { font-size: 0.8rem; color: var(--text-light); text-align: center; margin-top: 4px; }
.clearfix::after { content: ''; display: table; clear: both; }

/* ---- Full-width image ---- */
.img-full { width: 100%; max-height: 420px; object-fit: cover; display: block; }

/* ---- Card grid ---- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.card img { width: 100%; height: 200px; object-fit: cover; }
.card-body { padding: 20px; }
.card-body h3 { margin-bottom: 8px; }
.card-body p { font-size: 0.9rem; margin-bottom: 0; }

/* ---- Accommodation listing ---- */
.accom-item { padding: 24px 0; border-bottom: 1px solid var(--border); }
.accom-item:last-child { border-bottom: none; }
.accom-item h3 { margin-bottom: 6px; }
.accom-item .contact-info {
  background: var(--light-bg);
  border-left: 3px solid var(--accent);
  padding: 12px 16px;
  margin-top: 12px;
  font-size: 0.9rem;
}
.accom-item .contact-info p { margin-bottom: 4px; }

/* ---- Two-column content ---- */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start; }

/* ---- Booking widget ---- */
.booking-wrap { margin: 24px 0; background: var(--light-bg); padding: 20px; border-radius: 6px; }
.booking-wrap p { margin-bottom: 12px; font-weight: 600; }

/* ---- Price table ---- */
.price-table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 0.9rem; }
.price-table th { background: var(--primary); color: #fff; padding: 10px 14px; text-align: left; font-family: var(--font-body); }
.price-table td { padding: 10px 14px; border-bottom: 1px solid var(--border); }
.price-table tr:last-child td { border-bottom: none; }
.price-table tr:nth-child(even) td { background: var(--light-bg); }

/* ---- Info box ---- */
.info-box {
  background: var(--light-bg);
  border-left: 4px solid var(--accent);
  padding: 16px 20px;
  margin: 20px 0;
  border-radius: 0 4px 4px 0;
}
.info-box p { margin-bottom: 8px; }
.info-box p:last-child { margin-bottom: 0; }

/* ---- CTA box ---- */
.cta-box {
  background: var(--light-bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 24px 28px;
  text-align: center;
  margin: 24px 0;
}
.cta-box h3 { margin-bottom: 10px; }
.cta-box .btn {
  display: inline-block;
  background: var(--primary);
  color: var(--white);
  padding: 10px 24px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  margin-top: 10px;
  transition: background 0.2s;
}
.cta-box .btn:hover { background: var(--primary-dark); color: var(--white); }

/* ---- Nearby / Day trips strip ---- */
.nearby-strip {
  background: var(--light-bg);
  border-top: 1px solid var(--border);
  padding: 12px 32px;
}
.nearby-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  max-width: 1100px;
  margin: 0 auto;
}
.nearby-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted, #888);
  margin-right: 4px;
  white-space: nowrap;
}
.nearby-pill {
  display: inline-block;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 4px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.nearby-pill:hover {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}

/* ---- Partner strip ---- */
.partner-strip {
  background: #eaf0f6;
  border-top: 1px solid var(--border);
  text-align: center;
  padding: 20px;
}

/* ---- Footer ---- */
.site-footer {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.7);
  padding: 40px 20px 0;
  font-size: 0.85rem;
  max-width: 100%;
}

.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2rem;
  text-align: left;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-bottom: 2rem;
}

.footer-brand strong { font-family: var(--font-heading); font-size: 1.1rem; color: #fff; display: block; margin-bottom: 0.5rem; }
.footer-brand p { line-height: 1.9; }

.footer-links h4 {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.footer-links ul { list-style: none; line-height: 2.2; padding: 0; }
.footer-links a { color: rgba(255,255,255,0.65); text-decoration: none; }
.footer-links a:hover { color: var(--accent); }

.footer-base {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 1.25rem 0 1.25rem;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
  text-align: center;
  max-width: var(--max-width);
  margin: 0 auto;
}
.footer-base a { color: rgba(255,255,255,0.4); }

/* ---- Responsive ---- */
@media (max-width: 1100px) {
  .nav-toggle { display: block; }

  .main-nav ul {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--primary-dark);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  }

  .main-nav ul.open { display: flex; }
  .main-nav a { padding: 14px 20px; }

  .dropdown-menu {
    display: none;
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: none;
    position: static;
    box-shadow: none;
    background: rgba(0,0,0,0.15);
    padding-top: 0;
    margin-top: 0;
  }

  .main-nav li.open .dropdown-menu { display: flex; }
  .two-col { grid-template-columns: 1fr; }
  .img-float-right, .img-float-left { float: none; max-width: 100%; margin: 0 0 16px 0; }
  .section, .section-alt { padding: 24px 16px; }
  .nearby-strip { padding: 10px 16px; }
}

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