@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght,SOFT@0,9..144,300..900,0..100;1,9..144,300..900,0..100&family=DM+Sans:opsz,wght@9..40,300..700&family=DM+Mono:wght@400;500&display=swap');

:root {
  --color-background: #FAF6EE;
  --color-background-2: #F5EFE6;
  --color-background-error: #F5DED7;
  --color-background-success: #E6EAD9;
  --color-main-1: #1B2A4E;
  --color-main-2: #C97B5A;
  --font-main: 'DM Sans', sans-serif;
  --font-title: 'Fraunces', serif;
  --font-mono: 'DM Mono', monospace;
  --color-text: #2E2E2E;
  --color-link: #1B2A4E;
  --color-label: #2E2E2E;
  --color-error: #96341F;
  --color-success: #4B5A34;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-main);
  font-style: normal;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--color-background);
  color: var(--color-text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--color-link);
}

ul, ol {
  padding-left: 30px;
}

/* ==========================================================================
   TYPOGRAPHY
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  font-weight: 400;
  line-height: normal;
  color: var(--color-text);
  font-variation-settings: "opsz" 144, "SOFT" 50;
}

h1 em, h2 em, h3 em, h4 em, h5 em, h6 em {
  font-family: var(--font-title);
  font-style: italic;
  font-weight: 300;
  color: var(--color-main-2);
  font-variation-settings: "opsz" 144, "SOFT" 100;
}

h1 {
  font-size: 90px;
  @media (max-width: 1024px) {
    font-size: 60px;
  }
}

h2 {
  font-size: 60px;
  @media (max-width: 1024px) {
    font-size: 48px;
  }
}

h3 {
  font-size: 48px;
  @media (max-width: 1024px) {
    font-size: 36px;
  }
}

h4 {
  font-size: 36px;
  @media (max-width: 1024px) {
    font-size: 24px;
  }
}

h5 {
  font-size: 24px;
  @media (max-width: 1024px) {
    font-size: 18px;
  }
}

h6 {
  font-size: 18px;
  @media (max-width: 1024px) {
    font-size: 16px;
  }
}

p, span, li {
  font-size: 16px;
  font-weight: 400;
  line-height: 150%;
  color: var(--color-text);
}

/* Small tracked mono label — eyebrows, tags, prices, coordinates */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-main-2);
}

/* ==========================================================================
   SPACING SYSTEM
   Unified top/bottom rhythm for sections and blocks. Main sections should
   share the same vertical padding (e.g. 120px) unless the design calls for
   something different. Use these utilities instead of one-off px values.
   ========================================================================== */

.mt-120 {
  margin-top: 120px;
  @media (max-width: 1360px) {
    margin-top: 60px;
  }
}

.mt-60 {
  margin-top: 60px;
  @media (max-width: 1360px) {
    margin-top: 30px;
  }
}

.mb-120 {
  margin-bottom: 120px;
  @media (max-width: 1360px) {
    margin-bottom: 60px;
  }
}

.mb-60 {
  margin-bottom: 60px;
  @media (max-width: 1360px) {
    margin-bottom: 30px;
  }
}

/* Standard gap between a section's title block (heading ± intro paragraph)
   and whatever content follows it (button, form, cards, etc.) */
.mb-36 {
  margin-bottom: 36px;
  @media (max-width: 1360px) {
    margin-bottom: 18px;
  }
}

.pt-120 {
  padding-top: 120px;
  @media (max-width: 1360px) {
    padding-top: 60px;
  }
}

.pt-60 {
  padding-top: 60px;
  @media (max-width: 1360px) {
    padding-top: 30px;
  }
}

.pb-120 {
  padding-bottom: 120px;
  @media (max-width: 1360px) {
    padding-bottom: 60px;
  }
}

.pb-60 {
  padding-bottom: 60px;
  @media (max-width: 1360px) {
    padding-bottom: 30px;
  }
}

/* ==========================================================================
   BUTTON
   ========================================================================== */

.button {
  width: fit-content;
  height: 60px;
  padding: 0 36px;
  display: flex;
  align-items: center;
  gap: 6px;
  border-radius: 4px;
  font-weight: 500;
  text-decoration: none;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease, filter 0.25s ease;
}

.button:disabled {
  opacity: 0.5;
  pointer-events: none;
}

.button i {
  transition: transform 0.25s ease;
}

.button:hover i {
  transform: translateX(3px);
}

.button.btn-primary {
  background: var(--color-main-2);
  border-color: var(--color-main-2);
  color: var(--color-background);
}

.button.btn-primary:hover {
  filter: brightness(0.92);
}

/* Transparent + outlined — uses the current text color, so it reads
   correctly both on a light section and over a dark/image background.
   Hover fills with fixed tokens (cream background/border, navy text) rather
   than `background: currentColor`: that would resolve against this same
   rule's own new `color`, not the pre-hover value, so background and text
   would end up identical (invisible) in every context, not just one. */
.button.btn-ghost {
  background: transparent;
  border-color: currentColor;
  color: inherit;
}

.button.btn-ghost:hover {
  background: var(--color-background);
  border-color: var(--color-background);
  color: var(--color-main-1);
}

/* ==========================================================================
   NAV TOGGLE
   Hamburger button for collapsed nav (hidden on desktop — the breakpoint
   that shows it is defined per-project in style.css, next to that nav's own
   markup). main.js swaps the icon between ri-menu-line / ri-close-line and
   toggles .is-open on the nav it controls.
   ========================================================================== */

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  font-size: 24px;
  color: var(--color-text);
  cursor: pointer;
}

/* ==========================================================================
   SCROLL TO TOP
   Hidden until the page is scrolled past a threshold, then faded in.
   Toggled via .is-visible by main.js.
   ========================================================================== */

.scroll-top-btn {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-main-1);
  color: var(--color-background);
  border: none;
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.3s ease, transform 0.3s ease, background-color 0.2s ease;
  z-index: 998;
}

.scroll-top-btn.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.scroll-top-btn:hover {
  background: var(--color-main-2);
}

/* ==========================================================================
   LINK ARROW
   A text link with a visible icon bullet that nudges forward and picks up
   the accent color on hover — for nav/footer/menu items. Markup:
   <a class="link-arrow"><i class="ri-arrow-right-s-line"></i><span>Label</span></a>
   ========================================================================== */

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.link-arrow i {
  display: inline-block;
  font-size: 16px;
  line-height: 1;
  color: var(--color-main-2);
  transform: translateX(0);
  transition: transform 0.25s ease;
}

.link-arrow:hover {
  color: var(--color-main-2);
}

.link-arrow:hover i {
  transform: translateX(4px);
}

/* ==========================================================================
   CONTACT ITEM
   Pairs an icon with a contact detail (email, phone, address, ...). Markup:
   <a class="contact-item"><i class="ri-mail-line"></i><span>hello@example.com</span></a>
   ========================================================================== */

.contact-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.contact-item i {
  font-size: 16px;
  line-height: 1;
  color: var(--color-main-2);
}

a.contact-item:hover {
  color: var(--color-main-2);
}

/* ==========================================================================
   GRID (row / col)
   Minimal flex-based grid for laying out form fields side by side. Not a
   full breakpoint grid system — just enough to pair two fields on one row
   and let a field span the full row.

   <div class="row">
     <div class="col">...</div>       // shares the row with its siblings
     <div class="col col-12">...</div> // always spans the full row
   </div>
   ========================================================================== */

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}

.row .col {
  flex: 1 1 240px;
}

.row .col-12 {
  flex: 1 1 100%;
}

/* ==========================================================================
   FORMS
   Markup pattern (see forms/contact.php + forms/validate.js, which drives the
   submit/validation behavior behind these classes):

   <form class="contact-form-box php-email-form" data-action="forms/contact.php" novalidate>
     <div class="row">
       <div class="col">
         <div class="form-clt">
           <input class="access-input" name="name" ...>
           <span class="field-error" id="err-name">...</span>
         </div>
       </div>
       <div class="col col-12">
         <div class="form-clt">
           <select class="access-input select-input" name="package">...</select>
           <i class="ri-arrow-down-s-line select-caret"></i>
         </div>
       </div>
       <div class="col col-12">
         <div class="form-loading loading">...</div>
         <div class="form-error-msg error-message"><span></span></div>
         <div class="form-sent sent-message">...</div>
       </div>
       <div class="col col-12">
         <div class="contact-button">
           <button type="submit" class="button btn-primary">Send</button>
         </div>
       </div>
     </div>
   </form>
   ========================================================================== */

/* Bootstrap-style visibility hook: forms/validate.js toggles this class to
   reveal the loading/error/success states below. */
.d-block {
  display: block !important;
}

.contact-form-box {
  max-width: 640px;
  margin: 0 auto;
}

.form-clt {
  position: relative;
}

.access-input {
  width: 100%;
  height: 60px;
  padding: 0 18px;
  background: var(--color-background-2);
  border-radius: 4px;
  border: 2px solid var(--color-background-2);
  color: var(--color-text);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.access-input::placeholder {
  color: #9A9A9A;
}

.access-input:focus-visible {
  outline: none;
  border-color: var(--color-main-2);
}

textarea.access-input {
  height: auto;
  padding-top: 18px;
  padding-bottom: 18px;
  resize: none;
}

select.access-input {
  appearance: none;
  padding-right: 42px;
  cursor: pointer;
}

.select-caret {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: #9A9A9A;
}

.access-input.input-error {
  background: var(--color-background-error);
  border-color: var(--color-error);
  color: var(--color-error);
}

.access-input.input-error::placeholder {
  color: var(--color-error);
}

.field-error {
  display: none;
  margin-top: 6px;
  font-size: 14px;
  color: var(--color-error);
}

.field-error.visible {
  display: block;
}

/* Loading / error / success states start hidden; forms/validate.js shows
   the relevant one via .d-block. */
.loading,
.error-message,
.sent-message {
  display: none;
}

.form-loading {
  text-align: center;
  color: var(--color-text);
}

.form-loading-spinner {
  display: inline-block;
  vertical-align: middle;
  width: 18px;
  height: 18px;
  margin-right: 12px;
  border: 2px solid var(--color-background-2);
  border-top-color: var(--color-main-2);
  border-radius: 50%;
  animation: form-spin 0.6s linear infinite;
}

@keyframes form-spin {
  to {
    transform: rotate(360deg);
  }
}

.form-error-msg {
  padding: 12px 18px;
  background: var(--color-background-error);
  color: var(--color-error);
  border-radius: 4px;
}

.form-error-msg i {
  display: inline-block;
  vertical-align: middle;
  margin-right: 12px;
}

.form-sent {
  padding: 24px;
  background: var(--color-background-success);
  border-radius: 4px;
}

.form-sent-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin-bottom: 12px;
  background: var(--color-success);
  color: var(--color-background);
  font-weight: 700;
  border-radius: 50%;
}

.form-sent-title {
  margin-bottom: 6px;
  color: var(--color-success);
  font-weight: 500;
}

.form-sent-sub {
  color: var(--color-text);
}
