/* ===== Quaddra Haus brand palette ===== */
:root {
  --cream: #f3ecdd;
  --cream-2: #ebe2cf;
  --paper: #faf6ec;
  --green: #1f3a31;
  --green-deep: #16302a;
  --green-soft: #2d4a3e;
  --gold: #c9a55a;
  --gold-soft: #d9be7e;
  --ink: #1a2a24;
  --muted: #5b6b62;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: #d9d2c1;
  color: var(--ink);
  padding: 24px 0 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
}

/* ===== Toolbar ===== */
.toolbar {
  position: fixed;
  top: 16px;
  right: 16px;
  display: flex;
  gap: 8px;
  z-index: 10000;
}
.toolbar button {
  background: var(--green);
  color: var(--cream);
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0,0,0,.18);
  transition: transform .15s, background .15s;
}
.toolbar button:hover { background: var(--green-deep); transform: translateY(-1px); }

/* ===== Flyer canvas ===== */
.flyer {
  width: 860px;
  background: var(--cream);
  padding: 36px 32px 28px;
  box-shadow: 0 20px 60px rgba(0,0,0,.25);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* ===== Hero / header ===== */
.hero {
  display: grid;
  grid-template-columns: auto 1px 1fr;
  gap: 28px;
  align-items: center;
  padding: 8px 8px 18px;
}
.brand { display: flex; justify-content: center; align-items: center; }
.logo {
  width: 174px;
  height: auto;
  display: block;
}
.hero-divider { width: 1px; height: 130px; background: var(--green); opacity: .35; }
.hero-text h1 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 500;
  color: var(--green);
  font-size: 38px;
  line-height: 1.05;
  letter-spacing: 1px;
}
.gold-rule { width: 70px; height: 2px; background: var(--gold); margin: 12px 0 12px; }
.meta-row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--green-soft);
  font-size: 16px;
  margin: 4px 0;
}
.meta-row .ico {
  width: 18px;
  height: 18px;
  color: var(--gold);
  flex-shrink: 0;
}

/* Generic SVG icon sizing inside circular badges */
.head-icon svg, .start-icon svg, .tip-ico svg, .tips-star svg {
  width: 60%;
  height: 60%;
  color: var(--gold);
}
.tagline .heart {
  width: 18px;
  height: 18px;
  color: var(--gold);
}

/* ===== Start banner ===== */
.start-banner {
  position: relative;
  background: var(--green);
  color: var(--cream);
  border-radius: 6px;
  padding: 22px 26px;
  display: flex;
  align-items: center;
  gap: 22px;
  overflow: hidden;
}
.start-icon {
  width: 56px; height: 56px;
  border: 1.5px solid var(--gold);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  color: var(--gold);
  flex-shrink: 0;
}
.start-label {
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--gold-soft);
  margin-bottom: 4px;
}
.start-address { font-size: 18px; line-height: 1.35; font-weight: 400; }
.start-address strong { font-weight: 600; }
.start-dots {
  position: absolute;
  right: 18px; top: 50%;
  transform: translateY(-50%);
  width: 130px; height: 80px;
  pointer-events: none;
  /* Multi-stop dot grid: each dot stop uses different gold opacity so
     the field reads as scattered/twinkling rather than uniform. */
  background-image:
    radial-gradient(circle at center, rgba(217,190,126,.85) 1.2px, transparent 1.4px),
    radial-gradient(circle at center, rgba(217,190,126,.45) 1.2px, transparent 1.4px),
    radial-gradient(circle at center, rgba(217,190,126,.18) 1.2px, transparent 1.4px);
  background-size: 12px 12px, 12px 12px, 12px 12px;
  background-position: 0 0, 6px 6px, 0 6px;
  /* Soft fade into the green at the left edge */
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 35%, #000 100%);
          mask-image: linear-gradient(to right, transparent 0%, #000 35%, #000 100%);
  opacity: .9;
}

/* ===== Cards ===== */
.card {
  background: var(--paper);
  border-radius: 6px;
  padding: 22px 22px 24px;
}
.card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.head-icon {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--green);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.card-head h2 {
  font-family: 'Cormorant Garamond', serif;
  color: var(--green);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: 1.5px;
}
.subtitle { color: var(--muted); font-size: 13px; margin-top: 2px; }

/* ===== Route section ===== */
.route-section {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: 14px;
}

/* Timeline */
.timeline { list-style: none; position: relative; padding-left: 4px; }
.timeline li {
  position: relative;
  padding-left: 44px;
  padding-bottom: 18px;
  min-height: 70px;
}
.timeline li::before {
  content: '';
  position: absolute;
  left: 14px; top: 30px; bottom: -8px;
  width: 0;
  border-left: 2px dashed var(--gold);
}
.timeline li:last-child::before { display: none; }
.timeline .num {
  position: absolute;
  left: 0; top: 0;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--green);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px;
  font-weight: 600;
  z-index: 1;
}
.timeline .time-pill {
  display: inline-block;
  background: var(--cream-2);
  border: 1px solid var(--gold-soft);
  border-radius: 4px;
  padding: 4px 12px;
  font-weight: 600;
  color: var(--green);
  font-size: 14px;
  margin-bottom: 6px;
}
.timeline .addr {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.45;
}
.timeline .end-flag {
  position: absolute;
  left: 0; bottom: 0;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--green);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
}
.timeline .end-flag svg { width: 60%; height: 60%; }

/* Map */
.map-card { display: flex; flex-direction: column; }
#map {
  flex: 1;
  min-height: 540px;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--cream-2);
}
.leaflet-container { background: #e8efe9; font-family: 'Inter', sans-serif; }
.stop-marker {
  background: var(--green);
  color: var(--gold);
  width: 28px; height: 28px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
  font-size: 13px;
  border: 2px solid var(--cream);
  box-shadow: 0 2px 6px rgba(0,0,0,.3);
}
.start-marker, .end-marker {
  background: var(--green);
  color: var(--gold);
  width: 30px; height: 30px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--cream);
  box-shadow: 0 2px 6px rgba(0,0,0,.3);
  font-size: 14px;
}

/* ===== Properties grid ===== */
.properties-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 28px;
}
.prop {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 10px;
  align-items: start;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--cream-2);
}
.prop:nth-last-child(-n+2) { border-bottom: none; }
.prop .pnum {
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--green);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
  font-weight: 600;
}
.prop .pname { font-weight: 600; color: var(--green); font-size: 14px; }
.prop .paddr { color: var(--ink); font-size: 12.5px; line-height: 1.4; margin-top: 2px; }

/* ===== Tips ===== */
.tips-banner {
  background: var(--green);
  color: var(--cream);
  border-radius: 6px;
  padding: 18px 26px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 22px;
  align-items: center;
}
.tips-title {
  display: flex; align-items: center; gap: 10px;
  border-right: 1px solid rgba(217,190,126,.3);
  padding-right: 22px;
}
.tips-star {
  width: 38px; height: 38px;
  border: 1.5px solid var(--gold);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold);
}
.tips-label {
  font-size: 11px;
  letter-spacing: 2.5px;
  color: var(--gold-soft);
  font-weight: 600;
}
.tips-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.tip {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11.5px;
  line-height: 1.35;
  color: var(--cream);
}
.tip-ico {
  width: 32px; height: 32px;
  border: 1px solid rgba(217,190,126,.5);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold);
  font-size: 14px;
  flex-shrink: 0;
}

/* ===== Tagline ===== */
.tagline {
  text-align: center;
  padding: 14px 0 4px;
  color: var(--green);
  font-family: 'Cormorant Garamond', serif;
  font-size: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  border-top: 1px solid rgba(31,58,49,.15);
  margin-top: 6px;
}
.heart { color: var(--gold); }

/* ===== Modal ===== */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--paper);
  padding: 24px;
  border-radius: 10px;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
}
.modal h3 { color: var(--green); margin-bottom: 14px; font-family: 'Cormorant Garamond', serif; font-size: 22px; }
.modal h4 { color: var(--green); margin: 14px 0 6px; font-size: 14px; }
.modal label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 10px;
}
.modal input, .modal textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 8px 10px;
  border: 1px solid var(--cream-2);
  border-radius: 6px;
  font-family: inherit;
  font-size: 14px;
  background: white;
}
.modal textarea { font-family: 'Menlo', monospace; font-size: 12px; }
.modal-actions {
  display: flex; justify-content: flex-end; gap: 8px;
  margin-top: 16px;
}
.modal-actions button {
  padding: 9px 18px;
  border-radius: 6px;
  border: 1px solid var(--cream-2);
  background: white;
  cursor: pointer;
  font-family: inherit;
}
.modal-actions button.primary {
  background: var(--green);
  color: var(--cream);
  border-color: var(--green);
}
