/*
Theme Name: Swisan Group
Theme URI: https://swisan.tz
Author: Swisan Group
Description: Elementor-ready theme for Swisan Group, official Haier partner and reseller in Zanzibar. Creates Home, About Us, Catalogue, Our Story, Gallery, and Contact on activation.
Version: 1.2.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: swisan
Tags: custom-menu, custom-logo, featured-images, footer-widgets, full-width-template
*/

:root {
  --ink: #101828;
  --muted: #5c6778;
  --paper: #f3f5f8;
  --surface: #ffffff;
  --line: #e2e6ee;
  --brand: #0041c2;
  --brand-deep: #002f8f;
  --brand-soft: #e7eefc;
  --on-brand: #f7f9ff;
  --on-ink: #eef2f8;
  --on-ink-muted: #b7c0ce;
  --sans: "Source Sans 3", "Segoe UI", sans-serif;
  --display: "Outfit", "Segoe UI", sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.55;
}

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

h1, h2, h3, h4 {
  font-family: var(--display);
  line-height: 1.15;
  text-wrap: balance;
}

p { text-wrap: pretty; }

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

button,
.menu-toggle,
.btn { cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--surface);
  color: var(--ink);
  padding: 0.5rem 0.75rem;
  z-index: 50;
}
.skip:focus { top: 0.5rem; }

.sg-wrap {
  width: min(72rem, calc(100% - 2.5rem));
  margin-inline: auto;
}

.site-chrome {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--surface);
}
body.admin-bar .site-chrome { top: 32px; }

.topbar {
  background: var(--brand);
  color: var(--on-brand);
  font-size: 0.95rem;
}
.topbar a { color: var(--on-brand); text-decoration: none; }
.topbar a:hover { text-decoration: underline; }
.topbar-inner,
.header-inner,
.band-inner,
.block-head,
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
}
.topbar-inner { padding: 0.45rem 0; }
.topbar p { margin: 0; }
.topbar-links { display: flex; flex-wrap: wrap; gap: 0.35rem 1rem; }

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.header-inner { padding: 0.7rem 0; align-items: center; }

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink);
  text-decoration: none;
}
.mark {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.4rem;
  background: var(--brand);
  color: var(--on-brand);
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.25rem;
}
.logo-text { display: flex; flex-direction: column; line-height: 1; }
.logo-text strong {
  font-family: var(--display);
  font-size: 1.15rem;
  letter-spacing: 0.04em;
}
.logo-text small {
  margin-top: 0.25rem;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.menu-toggle {
  margin-left: auto;
  min-width: 2.75rem;
  min-height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 0.4rem;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-weight: 600;
}
.primary-nav { display: none; width: 100%; }
.primary-nav.is-open { display: block; padding-bottom: 0.5rem; }
.menu,
.footer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.menu a,
.footer-menu a {
  display: inline-flex;
  padding: 0.7rem 0.75rem;
  border-radius: 0.4rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
}
.menu .current-menu-item > a,
.menu .current_page_item > a {
  background: var(--brand-soft);
  color: var(--brand);
}
.menu a:hover { background: var(--paper); }

.sg-eyebrow,
.elementor-widget-heading h6 {
  margin: 0;
  color: var(--brand);
  font-family: var(--display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero {
  display: grid;
  background: var(--surface);
}
.hero-copy { padding: 3.2rem 1.25rem; }
.hero h1,
.page-intro h1,
.sg-article h1 {
  margin: 0.6rem 0 0;
  font-size: clamp(2rem, 4vw, 3.25rem);
  font-weight: 600;
}
.lead, .lede { color: var(--muted); font-size: 1.15rem; max-width: 40rem; }
.hero-photo img { width: 100%; height: 18rem; object-fit: cover; }

.facts { background: var(--paper); border-bottom: 1px solid var(--line); }
.facts ol {
  list-style: none;
  margin: 0;
  padding: 2.5rem 0;
  width: min(72rem, calc(100% - 2.5rem));
  margin-inline: auto;
  display: grid;
  gap: 1.5rem;
}
.facts span {
  color: var(--brand);
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: 0.12em;
}
.facts h2, .block h2, .band h2, .steps h2 { margin: 0.35rem 0; font-size: 1.6rem; }
.facts p { margin: 0; color: var(--muted); }

.block { padding: 3rem 0 3.5rem; }
.block-head { align-items: flex-end; margin-bottom: 1.25rem; }
.cards {
  display: grid;
  gap: 1.1rem;
}
.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  background: var(--surface);
  color: inherit;
  text-decoration: none;
}
.card img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.card span, .card-static span { display: flex; flex-direction: column; gap: 0.35rem; padding: 1.1rem 1.15rem 1.25rem; }
.card strong { font-family: var(--display); font-size: 1.25rem; }
.card em { font-style: normal; color: var(--muted); }
.text-link { font-weight: 700; text-decoration: none; }
.text-link:hover { color: var(--brand-deep); }

.band { background: var(--brand); color: var(--on-brand); }
.band-inner { padding: 2.8rem 0; align-items: center; }
.band p { margin: 0.35rem 0 0; }
.band h2 { color: var(--on-brand); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.65rem 1.1rem;
  border-radius: 0.4rem;
  border: 1px solid transparent;
  background: var(--brand);
  color: var(--on-brand);
  font: inherit;
  font-weight: 700;
  text-decoration: none;
}
.btn:hover { background: var(--brand-deep); color: var(--on-brand); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { color: var(--brand); border-color: var(--brand); background: var(--surface); }
.btn-light { background: var(--surface); color: var(--brand); }
.btn-light:hover { background: var(--paper); color: var(--brand); }
.actions { display: flex; flex-wrap: wrap; gap: 0.7rem; }

.page-intro { padding: 3rem 0 2rem; background: var(--surface); border-bottom: 1px solid var(--line); }
.split {
  display: grid;
  gap: 2rem;
  padding: 3rem 0 4rem;
  align-items: center;
}
.ticks { padding-left: 1.1rem; }
.ticks li { margin: 0.4rem 0; }
.frame img, .gallery img { width: 100%; border-radius: 0.6rem; object-fit: cover; }
.prose p { font-size: 1.15rem; }
.note { color: var(--muted); font-size: 0.95rem; }

.gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.8rem;
}
.gallery figure { margin: 0; }
.gallery img { aspect-ratio: 1; }
.gallery figcaption { padding: 0.55rem 0.15rem 0.2rem; font-weight: 700; }

.details p { margin: 0.2rem 0 1rem; }
.sg-form {
  display: grid;
  gap: 0.85rem;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  background: var(--surface);
}
.sg-form h2 { margin: 0; font-size: 1.5rem; }
.sg-form label { display: grid; gap: 0.3rem; font-weight: 700; font-size: 0.95rem; }
.sg-form input,
.sg-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 0.4rem;
  padding: 0.7rem 0.75rem;
  font: inherit;
  font-weight: 400;
  color: var(--ink);
  background: var(--surface);
}

.site-footer { background: var(--ink); color: var(--on-ink); }
.site-footer a { color: var(--on-ink); text-decoration: none; }
.site-footer a:hover { color: var(--surface); }
.footer-grid { padding: 3rem 0; align-items: flex-start; display: grid; gap: 2rem; }
.footer-label {
  margin: 0 0 0.4rem;
  color: var(--on-ink-muted);
  font-family: var(--display);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.logo-light,
.logo-light strong { color: var(--on-ink); }
.logo-light small { color: var(--on-ink-muted); }
.footer-menu a { padding: 0.25rem 0; color: var(--on-ink); }
.legal {
  margin: 0;
  padding-top: 1rem;
  padding-bottom: 1rem;
  border-top: 1px solid rgb(238 242 248 / 0.15);
  color: var(--on-ink-muted);
  font-size: 0.92rem;
}
.footer-widgets {
  display: grid;
  gap: 1.5rem;
  padding-top: 2.5rem;
}
.widget-title { font-size: 1rem; margin: 0 0 0.5rem; }

.sg-article { padding: 3rem 0 4rem; }

@media (max-width: 782px) {
  body.admin-bar .site-chrome { top: 46px; }
}

.steps { background: var(--surface); border-bottom: 1px solid var(--line); }
.steps-inner { width: min(72rem, calc(100% - 2.5rem)); margin-inline: auto; padding: 3.2rem 0; }
.steps h2 { font-size: clamp(1.7rem, 3vw, 2.1rem); }
.step-grid {
  list-style: none;
  margin: 1.6rem 0 0;
  padding: 0;
  display: grid;
  gap: 1.4rem;
}
.step-grid span {
  color: var(--brand);
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: 0.12em;
}
.step-grid h3 { margin: 0.35rem 0; font-size: 1.25rem; }
.step-grid p { margin: 0; color: var(--muted); }
.catalogue-block { background: var(--paper); }

.band-copy, .band-inner > div { flex: 1 1 18rem; max-width: 40rem; min-width: 0; }
.band p { margin: 0.35rem 0 0; max-width: 36rem; }

.sg-form { grid-template-columns: 1fr; }
.sg-form select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 0.4rem;
  padding: 0.7rem 0.75rem;
  font: inherit;
  font-weight: 400;
  color: var(--ink);
  background: var(--surface);
}
.shot {
  display: block;
  width: 100%;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  background: var(--surface);
  overflow: hidden;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
}
.shot img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.shot span { display: block; padding: 0.7rem 0.8rem 0.85rem; font-weight: 700; }
.lightbox {
  width: min(56rem, calc(100% - 2rem));
  border: 0;
  padding: 0;
  background: transparent;
}
.lightbox figure { margin: 0; overflow: hidden; border-radius: 0.6rem; background: var(--surface); }
.lightbox img { width: 100%; max-height: 70vh; object-fit: contain; background: var(--paper); }
.lightbox figcaption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 1rem;
}
.lightbox-close {
  border: 0;
  background: transparent;
  color: var(--brand);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

@media (min-width: 700px) {
  .sg-form { grid-template-columns: 1fr 1fr; }
  .sg-form h2,
  .sg-form .full,
  .sg-form button,
  .sg-form .form-status { grid-column: 1 / -1; }
}

@media (min-width: 800px) {
  .menu-toggle { display: none; }
  .primary-nav { display: block; width: auto; margin-left: auto; }
  .menu { flex-direction: row; align-items: center; }
  .hero { grid-template-columns: 1fr 1fr; }
  .hero-copy { padding: 4.5rem 3rem; }
  .hero-photo img { height: 100%; min-height: 28rem; }
  .facts ol, .cards, .cards-6, .step-grid { grid-template-columns: repeat(3, 1fr); }
  .split { grid-template-columns: 1.1fr 0.9fr; }
  .gallery { grid-template-columns: repeat(4, 1fr); }
  .footer-grid, .footer-widgets { grid-template-columns: repeat(3, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
