/* Contact page (contact.php). Loaded only on that page; uses the tokens from style.css. */

/* ---------- Hero with quick contact ---------- */
.ct-hero { position: relative; padding: clamp(40px, 6vw, 76px) 0 clamp(28px, 4vw, 44px); overflow: hidden; }
.ct-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 80% at 100% 0%, color-mix(in srgb, var(--primary) 14%, transparent), transparent 70%),
    radial-gradient(50% 70% at 0% 100%, color-mix(in srgb, var(--dark) 7%, transparent), transparent 70%);
}
[dir="rtl"] .ct-hero::before { transform: scaleX(-1); }
.ct-hero-text { max-width: 720px; margin-bottom: clamp(24px, 4vw, 36px); }
.ct-hero-text h1 { margin-bottom: .3em; }
.ct-hero-text .lead { margin: 0; max-width: 620px; }
.ct-eyebrow {
  display: inline-flex; align-items: center; gap: 6px; margin-bottom: 14px; padding: 5px 12px; border-radius: 999px;
  font-size: .85rem; font-weight: 700; color: var(--primary); background: color-mix(in srgb, var(--primary) 10%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--primary) 22%, transparent);
}

.ct-quick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.ct-q {
  position: relative; display: flex; align-items: center; gap: 14px; min-width: 0; padding: 18px;
  border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow);
  text-decoration: none; color: var(--text); transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.ct-q:hover { color: var(--text); transform: translateY(-3px); border-color: color-mix(in srgb, var(--primary) 45%, var(--line)); box-shadow: 0 14px 30px rgba(14, 27, 43, .1); }
.ct-q-ic { flex: none; width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; color: var(--primary); background: color-mix(in srgb, var(--primary) 11%, var(--surface)); }
.ct-q-body { display: grid; gap: 2px; min-width: 0; flex: 1; }
.ct-q-body strong { font-weight: 800; color: var(--dark); line-height: 1.35; overflow-wrap: anywhere; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ct-q-body small { color: var(--muted); font-size: .86rem; line-height: 1.45; }
.ct-q-go { flex: none; color: var(--muted); opacity: .55; transition: opacity .2s, transform .2s; }
.ct-q:hover .ct-q-go { opacity: 1; color: var(--primary); }
.ct-ltr { unicode-bidi: plaintext; }
[dir="rtl"] .ct-ltr { justify-content: flex-end; text-align: right; }
.ct-q.is-wa { background: linear-gradient(135deg, #1FA855, #17914A); border-color: transparent; color: #fff; box-shadow: 0 12px 28px rgba(31, 168, 85, .28); }
.ct-q.is-wa .ct-q-ic { background: rgba(255, 255, 255, .18); color: #fff; }
.ct-q.is-wa strong, .ct-q.is-wa small, .ct-q.is-wa .ct-q-go { color: #fff; }
.ct-q.is-wa small { opacity: .9; }
.ct-q.is-wa:hover { color: #fff; border-color: transparent; box-shadow: 0 16px 34px rgba(31, 168, 85, .36); }
.ct-badge { font-style: normal; font-size: .7rem; font-weight: 800; padding: 2px 8px; border-radius: 999px; background: #fff; color: #17914A; letter-spacing: .02em; }

/* ---------- Form + visit card ---------- */
.ct-main { padding-top: clamp(16px, 3vw, 28px); }
.ct-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: clamp(20px, 3vw, 32px); align-items: start; scroll-margin-top: 90px; }
#message { scroll-margin-top: 80px; }
.ct-form-card { padding: clamp(20px, 3.4vw, 36px); }
.ct-form-head h2 { margin-bottom: 4px; font-size: 1.45rem; }
.ct-form-head p { margin: 0 0 20px; }
.ct-form { gap: 18px; }
.ct-form .req { color: var(--primary); }
.ct-form .ct-opt { color: var(--muted); font-weight: 500; font-size: .85rem; }
.ct-form .field input, .ct-form .field select, .ct-form .field textarea { min-height: 50px; }
.ct-form .field textarea { min-height: 140px; }
.ct-form fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.ct-form legend { font-weight: 600; font-size: .95rem; color: var(--dark); margin-bottom: 10px; padding: 0; }

.ct-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ct-chip { position: relative; cursor: pointer; }
.ct-chip input, .ct-seg input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.ct-chip span {
  display: inline-flex; align-items: center; min-height: 40px; padding: 7px 16px; border-radius: 999px; font-size: .92rem; font-weight: 600;
  background: var(--surface); border: 1.5px solid var(--line); color: var(--text); transition: background .15s, border-color .15s, color .15s;
}
.ct-chip:hover span { border-color: color-mix(in srgb, var(--primary) 55%, var(--line)); }
.ct-chip input:checked + span { background: var(--dark); border-color: var(--dark); color: #fff; }
.ct-chip input:focus-visible + span, .ct-seg input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }

.ct-seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 5px; border-radius: 16px; background: var(--soft); border: 1px solid var(--line); }
.ct-seg label { position: relative; cursor: pointer; }
.ct-seg span { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 6px 10px; border-radius: 12px; font-weight: 600; font-size: .92rem; color: var(--muted); transition: background .15s, color .15s, box-shadow .15s; }
.ct-seg label:hover span { color: var(--dark); }
.ct-seg input:checked + span { background: var(--surface); color: var(--dark); box-shadow: 0 1px 2px rgba(14, 27, 43, .08), 0 4px 12px rgba(14, 27, 43, .06); }
.ct-seg input:checked + span .icon { color: var(--primary); }

.field-hint { margin: 0; font-size: .82rem; color: var(--muted); }
.field-error { display: flex; align-items: center; gap: 6px; margin: 0; font-size: .86rem; font-weight: 600; color: #B42318; }
.field-error .icon { flex: none; }
.field.has-error input, .field.has-error textarea, .field.has-error select { border-color: #D92D20; background: #FFFBFA; }
.field.has-error input:focus, .field.has-error textarea:focus { box-shadow: 0 0 0 3px rgba(217, 45, 32, .16); border-color: #D92D20; }
.field.has-error .field-hint { display: none; }
.field.has-error .check input { outline: 2px solid #D92D20; outline-offset: 1px; }
.field-foot { display: flex; align-items: center; gap: 12px; }
.ct-count { margin-inline-start: auto; font-size: .8rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.ct-form .check { color: var(--text); }
.ct-form .check a { color: var(--primary); }

.ct-submit { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding-top: 4px; }
.ct-submit .btn { min-width: 220px; }
.btn.is-loading { opacity: .85; cursor: progress; transform: none; }
.btn.is-loading .icon { animation: ct-pulse 1s ease-in-out infinite; }
@keyframes ct-pulse { 50% { opacity: .3; } }

.ct-done { text-align: center; display: grid; justify-items: center; gap: 6px; padding: clamp(16px, 4vw, 40px) 0; outline: none; }
.ct-done h2 { margin: 12px 0 0; font-size: 1.6rem; }
.ct-done p { max-width: 440px; margin: 0 0 8px; }
.ct-done .btn-row { justify-content: center; }

/* Visit card */
.ct-aside { position: sticky; top: 96px; }
.ct-visit { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.ct-map { aspect-ratio: 16 / 10; background: var(--soft); }
.ct-map iframe { width: 100%; height: 100%; border: 0; display: block; }
.ct-visit-body { padding: clamp(18px, 2.6vw, 26px); }
.ct-visit-body h2 { margin-bottom: 8px; }
.ct-addr { display: flex; align-items: flex-start; gap: 8px; margin: 0 0 14px; font-weight: 600; }
.ct-addr .icon { color: var(--primary); margin-top: 4px; }
.ct-dir { margin-bottom: 4px; }
.ct-sub { display: flex; align-items: center; gap: 8px; margin: 20px 0 8px; font-size: .95rem; font-weight: 700; color: var(--dark); }
.ct-sub .icon { color: var(--primary); }
.ct-socials { display: flex; flex-wrap: wrap; gap: 8px; }
.ct-socials a { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--soft); color: var(--dark); transition: background .15s, color .15s; }
.ct-socials a:hover { background: var(--primary); color: #fff; }

/* Compact form (v2) */
.ct-form-card { padding: clamp(18px, 2.6vw, 28px); }
.ct-form-head h2 { font-size: 1.25rem; margin-bottom: 14px; }
.ct-form { gap: 12px; }
.ct-form .grid-2 { gap: 12px; }
.ct-form .field { gap: 4px; }
.ct-form .field label, .ct-form legend { font-size: .88rem; }
.ct-form .field input, .ct-form .field select { min-height: 44px; padding-block: 8px; font-size: .95rem; }
.ct-form .field textarea { min-height: 92px; font-size: .95rem; }
.ct-form .ct-reply { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ct-form .ct-reply legend { float: inline-start; margin: 0; }
.ct-form .ct-seg { display: inline-grid; grid-template-columns: repeat(3, auto); gap: 4px; padding: 3px; border-radius: 12px; }
.ct-form .ct-seg span { min-height: 34px; padding: 4px 12px; font-size: .85rem; border-radius: 9px; gap: 6px; }
.ct-form .check { font-size: .88rem; }
.ct-form .check input { width: 20px; height: 20px; margin-top: 2px; }
.ct-form .ct-send { min-height: 48px; min-width: 200px; }
@media (max-width: 620px) { .ct-form .ct-send { justify-self: stretch; } }

/* ---------- Brand directory ---------- */
.ct-sec-head { margin-bottom: 26px; }
.ct-sec-head .section-title { margin-bottom: 4px; }
.ct-sec-head p { margin: 0; }
.ct-brands { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.ct-brand {
  position: relative; display: flex; flex-direction: column; gap: 12px; padding: 20px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.ct-brand::before { content: ""; position: absolute; inset: 0 0 auto; height: 4px; background: var(--c); }
.ct-brand:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--c) 40%, var(--line)); box-shadow: 0 16px 34px rgba(14, 27, 43, .1); }
.ct-brand header { display: flex; align-items: center; gap: 14px; }
.ct-brand-logo { flex: none; width: 76px; height: 56px; border-radius: 16px; padding: 6px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 10%, #fff); border: 1px solid color-mix(in srgb, var(--c) 20%, var(--line)); overflow: hidden; text-decoration: none; }
.ct-brand-logo img { width: 100%; height: 100%; object-fit: contain; }
.ct-brand-logo span { font-weight: 800; font-size: 1.4rem; color: var(--c); }
.ct-brand header > div { min-width: 0; }
.ct-brand .tag { font-size: .72rem; padding: 2px 9px; }
.ct-brand h3 { margin: 4px 0 0; font-size: 1.1rem; }
.ct-brand h3 a { text-decoration: none; }
.ct-brand h3 a:hover { color: var(--c); }
.ct-brand-phone { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; font-family: "Inter", var(--font); font-weight: 700; font-size: 1.15rem; text-decoration: none; color: var(--dark); }
.ct-brand-phone .icon { color: var(--c); }
.ct-brand-hours { border-top: 1px dashed var(--line); padding-top: 10px; }
.ct-brand-hours summary { cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: 6px; min-height: 32px; font-size: .9rem; font-weight: 600; color: var(--muted); }
.ct-brand-hours summary::-webkit-details-marker { display: none; }
.ct-brand-hours summary::after { content: "+"; margin-inline-start: 4px; color: var(--c); font-size: 1.1rem; line-height: 1; }
.ct-brand-hours[open] summary::after { content: "–"; }
.ct-brand-hours summary:hover { color: var(--dark); }
.ct-brand-hours .loc-hours li { font-size: .84rem; padding: 5px 9px; }
.ct-brand-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: auto; padding-top: 4px; }
.ct-brand-actions .btn { min-height: 42px; padding: 6px 12px; font-size: .88rem; }
.ct-brand-actions .btn-ghost { grid-column: 1 / -1; }
.ct-brand-actions .btn-ghost:hover { border-color: var(--c); color: var(--dark); }

/* ---------- FAQ ---------- */
.ct-faq-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: clamp(20px, 4vw, 48px); align-items: start; }
.ct-faq-grid .faq { margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .ct-quick { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ct-brands { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .ct-grid { grid-template-columns: 1fr; }
  .ct-aside { position: static; }
  .ct-faq-grid { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .ct-hero { padding-top: 28px; }
  .ct-quick { grid-template-columns: 1fr; gap: 10px; }
  .ct-q { padding: 14px; }
  .ct-q-ic { width: 44px; height: 44px; }
  .ct-brands { grid-template-columns: 1fr; gap: 14px; }
  .ct-submit .btn { width: 100%; }
  .ct-submit { gap: 10px; }
  .ct-chip span { min-height: 38px; padding: 6px 13px; font-size: .88rem; }
  .ct-seg span { font-size: .85rem; gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .ct-q, .ct-brand, .btn.is-loading .icon { transition: none; animation: none; }
  .ct-q:hover, .ct-brand:hover { transform: none; }
}
