/*
Theme Name:  Eco Bilvask Child
Theme URI:   https://ecobilvask.no
Template:    generatepress
Version:     1.0.0
Description: Child theme for Eco Bilvask — GeneratePress parent, untouched.
Author:      Tind
*/

/* ============================================================
   DESIGN TOKENS
   ============================================================ */
:root {
  --navy:        #001f5f;
  --navy-light:  #0a2d7a;
  --green:       #8dc63f;
  --green-dark:  #6fa832;
  --white:       #ffffff;
  --off-white:   #f8f9fb;
  --gray-light:  #f0f2f5;
  --gray-mid:    #d8dce4;
  --text:        #1a1a2e;
  --text-muted:  #5a5f72;
  --font:        'filson-pro', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --radius:      12px;
  --radius-lg:   20px;
  --shadow-sm:   0 2px 8px rgba(0, 31, 95, 0.07);
  --shadow:      0 4px 20px rgba(0, 31, 95, 0.10);
  --shadow-lg:   0 8px 40px rgba(0, 31, 95, 0.16);
  --transition:  0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --section-py:  90px;
  --container:   1200px;
}

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

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--green-dark); transition: color var(--transition); }
a:hover { color: var(--navy); }

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
  background: var(--navy) !important;
  padding: 0 !important;
}

.main-navigation a,
.main-navigation a:visited {
  color: var(--white) !important;
  font-weight: 600;
  letter-spacing: 0.02em;
  font-size: 0.95rem;
  padding: 28px 16px !important;
  transition: color var(--transition);
}

.main-navigation a:hover {
  color: var(--green) !important;
}

.site-branding {
  padding: 16px 0;
}

/* ============================================================
   SECTION UTILITY CLASSES
   ============================================================ */
.section-navy {
  background: var(--navy);
  color: var(--white);
  padding: var(--section-py) 0;
}

.section-green {
  background: var(--green);
  color: var(--white);
  padding: var(--section-py) 0;
}

.section-light {
  background: var(--off-white);
  padding: var(--section-py) 0;
}

.section-white {
  background: var(--white);
  padding: var(--section-py) 0;
}

/* ============================================================
   SECTION HEADINGS (banner style)
   ============================================================ */
.heading-navy {
  background: var(--navy);
  color: var(--white) !important;
  border-radius: var(--radius) !important;
  padding: 32px 40px !important;
  font-size: clamp(1.5rem, 3vw, 2rem) !important;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 32px;
}

.heading-green {
  background: var(--green);
  color: var(--white) !important;
  border-radius: var(--radius) !important;
  padding: 32px 40px !important;
  font-size: clamp(1.5rem, 3vw, 2rem) !important;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 32px;
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero-section {
  background: var(--navy);
  color: var(--white);
  padding: 100px 0 80px;
  position: relative;
  overflow: hidden;
}

.hero-section::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0,31,95,0.95) 40%, rgba(141,198,63,0.15) 100%);
  pointer-events: none;
}

.hero-headline {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 900;
  line-height: 1.1;
  color: var(--white);
  position: relative;
  z-index: 1;
}

.hero-headline span {
  color: var(--green);
}

.hero-sub {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: rgba(255,255,255,0.85);
  margin-top: 20px;
  max-width: 560px;
  line-height: 1.65;
  position: relative;
  z-index: 1;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--green);
  color: var(--white) !important;
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 28px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 4px 14px rgba(141,198,63,0.3);
}

.btn-primary:hover {
  background: var(--green-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(141,198,63,0.4);
  color: var(--white) !important;
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: var(--white) !important;
  font-weight: 700;
  font-size: 1rem;
  padding: 13px 27px;
  border-radius: var(--radius);
  border: 2px solid rgba(255,255,255,0.5);
  cursor: pointer;
  text-decoration: none;
  transition: border-color var(--transition), background var(--transition), transform var(--transition);
}

.btn-outline:hover {
  border-color: var(--white);
  background: rgba(255,255,255,0.1);
  transform: translateY(-2px);
  color: var(--white) !important;
}

/* ============================================================
   FEATURE CARDS (hero strip)
   ============================================================ */
.feature-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding: 0 0 20px;
}

.feature-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px 28px;
  box-shadow: var(--shadow);
  border-top: 4px solid var(--green);
  transition: transform var(--transition), box-shadow var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature-card__number {
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--green);
  line-height: 1;
  margin-bottom: 8px;
}

.feature-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 6px;
}

.feature-card__text {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ============================================================
   CONTENT SECTION: TEXT + IMAGE
   ============================================================ */
.content-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  padding: var(--section-py) 0;
}

.content-row--reverse {
  direction: rtl;
}

.content-row--reverse > * {
  direction: ltr;
}

.content-row__text {}

.content-row__text h2 {
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 16px;
  line-height: 1.25;
}

.content-row__text p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.content-row__image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.content-row__image img {
  width: 100%;
  height: 380px;
  object-fit: cover;
}

/* ============================================================
   PROGRAM CARDS (selvvask)
   ============================================================ */
.program-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 40px;
}

.program-card {
  background: var(--navy);
  border-radius: var(--radius);
  padding: 32px 24px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.program-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--green);
  transform: scaleX(0);
  transition: transform var(--transition);
  transform-origin: left;
}

.program-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  background: var(--navy-light);
}

.program-card:hover::before {
  transform: scaleX(1);
}

.program-card__label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 8px;
}

.program-card__number {
  font-size: 4rem;
  font-weight: 900;
  color: var(--green);
  line-height: 1;
  margin-bottom: 12px;
}

.program-card__title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 16px;
}

.program-card__btn {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--green);
  background: transparent;
  border: 1px solid rgba(141,198,63,0.4);
  border-radius: 6px;
  padding: 6px 16px;
  cursor: pointer;
  transition: background var(--transition), color var(--transition), border-color var(--transition);
  margin-top: auto;
}

.program-card__btn:hover {
  background: var(--green);
  color: var(--white);
  border-color: var(--green);
}

/* ============================================================
   POPOVER (wash program modals)
   ============================================================ */
[popover] {
  border: none;
  border-radius: var(--radius-lg);
  padding: 0;
  max-width: min(640px, 94vw);
  width: 100%;
  box-shadow: var(--shadow-lg);
  background: var(--white);
  overflow: hidden;
}

[popover]::backdrop {
  background: rgba(0, 10, 30, 0.65);
  backdrop-filter: blur(4px);
}

.popover-header {
  background: var(--navy);
  color: var(--white);
  padding: 28px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.popover-header h3 {
  font-size: 1.3rem;
  font-weight: 800;
  margin: 0;
  color: var(--white);
}

.popover-header .program-num {
  font-size: 2.8rem;
  font-weight: 900;
  color: var(--green);
  line-height: 1;
}

.popover-body {
  padding: 32px;
}

.popover-body img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 24px;
}

.popover-body h4 {
  font-size: 1rem;
  font-weight: 800;
  color: var(--navy);
  margin: 20px 0 6px;
}

.popover-body p {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.popover-close {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--green);
  color: var(--white);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 10px 20px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  margin-top: 16px;
  transition: background var(--transition);
}

.popover-close:hover { background: var(--green-dark); }

/* ============================================================
   GALLERY STRIP
   ============================================================ */
.gallery-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.gallery-strip img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: var(--radius);
  transition: transform var(--transition), box-shadow var(--transition);
}

.gallery-strip img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

/* ============================================================
   BUSINESS CUSTOMER CALLOUT
   ============================================================ */
.callout-navy {
  background: var(--navy);
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 48px 52px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: center;
}

.callout-navy h2 {
  font-size: clamp(1.3rem, 2.5vw, 1.7rem);
  font-weight: 800;
  color: var(--green);
  margin-bottom: 12px;
}

.callout-navy p {
  font-size: 0.95rem;
  line-height: 1.65;
  color: rgba(255,255,255,0.8);
  margin-bottom: 8px;
}

/* ============================================================
   CONTACT FORM
   ============================================================ */
.wpcf7 input:not([type="submit"]),
.wpcf7 textarea,
.wpcf7 select {
  width: 100%;
  border: 2px solid var(--gray-mid);
  border-radius: var(--radius);
  padding: 14px 18px;
  font-family: var(--font);
  font-size: 1rem;
  color: var(--text);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
  margin-bottom: 16px;
}

.wpcf7 input:focus,
.wpcf7 textarea:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(141,198,63,0.15);
}

.wpcf7 input[type="submit"] {
  background: var(--green);
  color: var(--white);
  font-family: var(--font);
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 32px;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}

.wpcf7 input[type="submit"]:hover {
  background: var(--green-dark);
  transform: translateY(-2px);
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--navy) !important;
  color: rgba(255,255,255,0.65) !important;
  padding: 40px 0 !important;
  font-size: 0.875rem;
}

.site-footer a {
  color: rgba(255,255,255,0.65);
  transition: color var(--transition);
}

.site-footer a:hover { color: var(--green); }

/* ============================================================
   SAL.JS — animation states
   ============================================================ */
[data-sal] {
  transition-property: opacity, transform;
  transition-duration: 0.7s;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
  .feature-cards { grid-template-columns: 1fr 1fr; }
  .program-grid  { grid-template-columns: 1fr 1fr; }
  .content-row   { grid-template-columns: 1fr; gap: 36px; }
  .content-row--reverse { direction: ltr; }
  .callout-navy  { grid-template-columns: 1fr; padding: 36px; }
}

@media (max-width: 600px) {
  :root { --section-py: 56px; }
  .feature-cards { grid-template-columns: 1fr; }
  .program-grid  { grid-template-columns: 1fr 1fr; }
  .gallery-strip { grid-template-columns: 1fr; }
  .heading-navy,
  .heading-green { padding: 24px 24px !important; }
  .hero-section  { padding: 72px 0 60px; }
  [popover]      { border-radius: var(--radius) var(--radius) 0 0; align-self: end; }
}
