/* ==========================================================================
   ERTIQA MARKETING  -  main stylesheet
   Colours and fonts come from theme.css (never hard-code a colour here).
   Sections follow the order of the company profile:
     1. Base          6. Vision & Mission     11. Contact
     2. Header        7. Our Value            12. Footer
     3. Shared parts  8. Our Services         13. Responsive
     4. Hero          9. Our Work + gallery
     5. About / etc.  10. Lightbox
   ========================================================================== */


/* 1. BASE ------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;           /* keeps headings clear of the fixed header */
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-background);
}

img { display: block; max-width: 100%; height: auto; }
a   { color: var(--color-secondary); }
p   { margin: 0 0 1rem; }
ul  { margin: 0; padding: 0; list-style: none; }

.container {
  width: min(100% - 3rem, 68rem);
  margin-inline: auto;
  position: relative;
  z-index: 1;                          /* sits above the decorative shapes */
}


/* 2. HEADER ----------------------------------------------------------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  background: var(--color-background);
  box-shadow: 0 0.1rem 1rem var(--color-shadow);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 4.5rem;
}

.logo img { height: 3.4rem; width: auto; }

.nav-list { display: flex; gap: 1.6rem; }

.nav-list a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text);
  text-decoration: none;
  padding-block: 0.3rem;
  border-bottom: 0.15rem solid transparent;
}
.nav-list a:hover,
.nav-list a.is-active { color: var(--color-secondary); border-bottom-color: var(--color-primary); }

.nav-toggle {                           /* hamburger, shown on mobile only */
  display: none;
  background: none;
  border: 0;
  padding: 0.5rem;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 1.6rem;
  height: 0.18rem;
  margin: 0.32rem 0;
  background: var(--color-secondary);
  transition: transform 0.2s, opacity 0.2s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(0.5rem) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-0.5rem) rotate(-45deg); }


/* 3. SHARED PARTS ----------------------------------------------------- */
.section {
  position: relative;
  overflow: hidden;
  padding: 5rem 0 7rem;                /* extra bottom room for the striped arch */
}
.section--first { padding-top: 8rem; }  /* clears the fixed header */

/* Two-line section title: small italic line + big bold gold line */
.section-title { margin: 0 0 1.5rem; line-height: 1.1; }
.title-lead {
  display: block;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--color-text);
}
.title-main {
  display: block;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: clamp(2.3rem, 5vw, 3.5rem);
  color: var(--color-primary);
}

/* Circular photo with a white ring (signature shape of the profile) */
.photo-circle {
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 0 0 0.45rem var(--color-background), 0 0.8rem 2rem var(--color-shadow);
}
.photo-circle img { width: 100%; height: 100%; object-fit: cover; }

/* Photo wrapper that adds a gold disc peeking out behind the photo */
.photo-wrap { position: relative; width: min(100%, 26rem); margin-inline: auto; }
.photo-wrap::before {
  content: "";
  position: absolute;
  width: 55%;
  aspect-ratio: 1;
  top: -12%;
  left: -14%;
  border-radius: 50%;
  background: var(--color-primary);
}
.photo-wrap--right::before { left: auto; right: -14%; }
.photo-wrap .photo-circle { position: relative; }

/* Decorative shapes (positioned per section with the modifiers below) */
.deco { position: absolute; z-index: 0; pointer-events: none; }

.deco-disc { border-radius: 50%; background: var(--color-primary); aspect-ratio: 1; }

.deco-half-disc {                       /* flat top, rounded bottom */
  background: var(--color-primary);
  aspect-ratio: 2 / 1;
  border-radius: 0 0 999px 999px;
}

/* Teal diagonal-striped arch: the recurring motif of the profile */
.deco-stripes {
  width: clamp(8rem, 14vw, 12rem);
  aspect-ratio: 2 / 1;
  background: repeating-linear-gradient(135deg, var(--color-secondary) 0 0.4rem, transparent 0.4rem 0.85rem);
  border-radius: 999px 999px 0 0;
  -webkit-mask: radial-gradient(circle farthest-side at 50% 100%, transparent 0 56%, black 57%);
          mask: radial-gradient(circle farthest-side at 50% 100%, transparent 0 56%, black 57%);
}
.deco-stripes--bottom-left { left: -3rem; bottom: 0; }
.deco-stripes--top-left    { left: -3rem; top: 0; transform: rotate(180deg); }

/* Gold icons: the colour is the mask's background, so it follows the theme */
.icon {
  display: inline-block;
  flex: none;
  width: 3.2rem;
  height: 3.2rem;
  background: var(--color-primary);
  -webkit-mask: var(--icon) center / contain no-repeat;
          mask: var(--icon) center / contain no-repeat;
}
.icon--small { width: 1.6rem; height: 1.6rem; }


/* 4. HERO ------------------------------------------------------------- */
.hero { min-height: 100vh; display: flex; align-items: center; }

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 2rem;
}

.hero-title-block {                     /* gold block holding the company name */
  width: fit-content;
  margin-right: -5rem;                  /* overlaps the photo, as in the profile */
  padding: 1.4rem 4rem 1.4rem 2rem;
  border-radius: 2rem 8rem 8rem 2rem;
  background: var(--color-primary);
  position: relative;
  z-index: 2;
}
.hero-title-block h1 { margin: 0; line-height: 1.05; }
.brand-lead {
  display: block;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(2.4rem, 6vw, 4rem);
  color: var(--color-secondary);
}
.brand-main {
  display: block;
  font-weight: 800;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  color: var(--color-on-primary);
}

.hero-years { display: flex; align-items: center; gap: 1rem; margin: 2rem 0 1rem; }
.years-number { font-size: clamp(4rem, 9vw, 6.5rem); font-weight: 800; line-height: 1; color: var(--color-primary); }
.years-text { max-width: 14rem; font-style: italic; font-size: 1.05rem; }

.hero-web { font-size: 0.9rem; font-weight: 600; }
.hero-tagline { max-width: 34rem; }

.hero-photo { position: relative; }
.hero-photo .photo-circle { width: min(100%, 32rem); margin-left: auto; }


/* 5. STATEMENT / CONTENTS / ABOUT ------------------------------------- */
.split { display: grid; grid-template-columns: 1.2fr 0.8fr; align-items: center; gap: 3rem; }

.statement-quote {
  margin: 0 0 1.5rem;
  padding-left: 1.5rem;
  border-left: 0.2rem solid var(--color-primary);
  font-style: italic;
}
.signature strong { display: block; }
.signature span   { color: var(--color-primary); font-style: italic; font-size: 0.95rem; }

.contents-list {
  display: grid;
  gap: 1rem;
  padding-left: 1.5rem;
  border-left: 0.2rem solid var(--color-primary);
}
.contents-list a {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  color: var(--color-text);
  text-decoration: none;
}
.contents-list a:hover { color: var(--color-secondary); }
.contents-number {
  min-width: 2rem;
  font-size: 2.2rem;
  font-weight: 800;
  font-style: italic;
  color: var(--color-secondary);
}

.about-body { max-width: 44rem; margin-inline: auto; text-align: center; }
.about-body .photo-wrap { width: min(100%, 17rem); margin-bottom: 2.5rem; }
.about-intro { font-style: italic; font-size: 1.15rem; }
.about-body .section-title { text-align: center; }


/* 6. VISION & MISSION ------------------------------------------------- */
.vision-intro { font-size: 1.1rem; }

.pillar { margin-top: 1.5rem; }
.pillar h3 {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 0.3rem;
  font-size: 1rem;
  color: var(--color-secondary);
}
.pillar h3::before {                    /* small gold square bullet */
  content: "";
  width: 0.6rem;
  height: 1.2rem;
  background: var(--color-primary);
}
.pillar p { font-style: italic; font-size: 0.95rem; }


/* 7. OUR VALUE -------------------------------------------------------- */
.section-intro { max-width: 40rem; margin: 0 auto 3rem; text-align: center; }
.centered-title { text-align: center; }

.values-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem 1.5rem; }
.value-card { text-align: center; }
.value-card .photo-circle { width: 9rem; margin: 0 auto 1rem; }
.value-card h3 { margin: 0 0 0.6rem; font-size: 1.15rem; color: var(--color-secondary); }
.value-card p {
  margin: 0;
  padding: 0.9rem 1.2rem;
  border-radius: 1.6rem;
  background: var(--color-primary);
  font-style: italic;
  font-size: 0.92rem;
  line-height: 1.5;
}


/* 8. OUR SERVICES ----------------------------------------------------- */
.services-lead { font-weight: 700; font-size: 1.1rem; }

.services-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2.2rem 3rem; margin-top: 3rem; }
.service { display: flex; gap: 1.1rem; }
.service h3 { margin: 0 0 0.3rem; font-size: 1.1rem; color: var(--color-secondary); }
.service p  { margin: 0; font-style: italic; font-size: 0.95rem; }


/* 9. OUR WORK + GALLERY ----------------------------------------------- */
.work-intro { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; margin-bottom: 3.5rem; }
.work-photo {
  aspect-ratio: 2.4 / 1;
  border-radius: 999px;
  overflow: hidden;
  box-shadow: 0 0 0 0.45rem var(--color-background), 0 0.8rem 2rem var(--color-shadow);
  margin-bottom: 2rem;
}
.work-photo img { width: 100%; height: 100%; object-fit: cover; }
.work-intro .section-title::after {     /* short gold underline under "Work" */
  content: "";
  display: block;
  width: 3.5rem;
  height: 0.2rem;
  margin-top: 0.8rem;
  background: var(--color-primary);
}
.work-text p { font-style: italic; }

.gallery { column-count: 4; column-gap: 0.75rem; }
.gallery-item {
  display: block;
  margin-bottom: 0.75rem;
  break-inside: avoid;
  border-radius: 0.5rem;
  overflow: hidden;
  background: var(--color-secondary-light);
}
.gallery-item img { width: 100%; transition: transform 0.3s; }
.gallery-item:hover img { transform: scale(1.04); }
.gallery-item img.is-tall { max-height: 34rem; object-fit: cover; object-position: top; }  /* long web pages */


/* 10. LIGHTBOX -------------------------------------------------------- */
.lightbox {
  width: min(94vw, 62rem);
  max-height: 94vh;
  padding: 0;
  border: 0;
  border-radius: 0.75rem;
  background: var(--color-background);
  overflow: auto;
}
.lightbox::backdrop { background: color-mix(in srgb, var(--color-text) 85%, transparent); }
.lightbox img { margin: 0 auto; }
.lightbox-btn {
  position: fixed;
  z-index: 2;
  width: 2.8rem;
  height: 2.8rem;
  border: 0;
  border-radius: 50%;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}
.lightbox-close { top: 1rem; right: 1rem; }
.lightbox-prev  { left: 1rem;  top: 50%; }
.lightbox-next  { right: 1rem; top: 50%; }


/* 11. CONTACT ("Thank You!") ------------------------------------------ */
.contact-card {
  width: min(100%, 40rem);
  padding: 2rem 3rem 2rem 2rem;
  border-radius: 1.5rem 12rem 12rem 1.5rem;
  background: var(--color-primary);
}
.contact-card h2 { margin: 0 0 1rem; font-style: italic; font-size: clamp(2rem, 4vw, 2.8rem); color: var(--color-on-primary); }
.contact-card .contact-photo { aspect-ratio: 3 / 1; border-radius: 999px; overflow: hidden; margin-bottom: 1.2rem; }
.contact-card .contact-photo img { width: 100%; height: 100%; object-fit: cover; }
.contact-card h3 { margin: 0; font-size: 1.6rem; font-weight: 600; color: var(--color-secondary); }

.contact-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.4rem 2rem; margin-top: 2.5rem; }
.contact-item { display: flex; align-items: flex-start; gap: 0.8rem; }
.contact-item a { color: var(--color-text); text-decoration: none; overflow-wrap: anywhere; }
.contact-item a:hover { color: var(--color-secondary); }


/* 12. FOOTER ---------------------------------------------------------- */
.site-footer { padding: 1.5rem 0; text-align: center; font-size: 0.85rem; color: var(--color-text-muted); border-top: 0.15rem solid var(--color-primary); }
.site-footer a { color: inherit; text-decoration: none; }


/* 13. RESPONSIVE ------------------------------------------------------ */
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav {
    position: absolute;
    inset: 100% 0 auto 0;
    display: none;
    padding: 1rem 1.5rem 1.5rem;
    background: var(--color-background);
    box-shadow: 0 0.6rem 1rem var(--color-shadow);
  }
  .nav.is-open { display: block; }
  .nav-list { flex-direction: column; gap: 0.9rem; }

  .section { padding: 3.5rem 0; }
  .hero { min-height: auto; }
  .hero-grid, .split, .work-intro { grid-template-columns: 1fr; gap: 2rem; }
  .hero-title-block { margin-right: 0; border-radius: 1.5rem 5rem 5rem 1.5rem; }
  .hero-photo .photo-circle { margin-inline: auto; width: min(100%, 22rem); }
  .photo-wrap { width: min(100%, 18rem); }

  .values-grid   { grid-template-columns: repeat(2, 1fr); }
  .services-grid { grid-template-columns: 1fr; }
  .gallery       { column-count: 2; }
  .contact-list  { grid-template-columns: 1fr; }
  .contact-card  { border-radius: 1.5rem 6rem 6rem 1.5rem; padding-right: 2rem; }
  .lightbox-prev, .lightbox-next { top: auto; bottom: 1rem; }
}

@media (max-width: 520px) {
  .values-grid { grid-template-columns: 1fr; }
}
