/* ========================================
   MEAS — Markveien Eiendom AS
   Teknisk, stilren — inspirert av oslotakst.as
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
  --accent: #1B2A3D;
  --accent-hover: #142130;
  --accent-light: #EDF1F5;
  --dark: #1A2332;
  --dark-footer: #1A2332;
  --text: #2C3E50;
  --text-light: #64748B;
  --text-muted: #94A3B8;
  --bg: #FFFFFF;
  --bg-light: #F8FAFB;
  --bg-card: #FFFFFF;
  --border: #E2E8F0;
  --white: #FFFFFF;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow: 0 4px 12px rgba(0,0,0,0.05);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.07);
  --radius: 6px;
  --radius-lg: 10px;
  --font: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --max-width: 1200px;
  --header-height: 72px;
  --transition: 0.2s ease;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ---- Typography ---- */
h1, h2, h3, h4 {
  font-family: var(--font);
  font-weight: 700;
  line-height: 1.2;
  color: var(--dark);
}
h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.35rem); }
p { max-width: 65ch; }

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: var(--white);
  z-index: 1000;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border);
}
.header-inner {
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.logo-mark {
  font-family: var(--font);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.04em;
  line-height: 1;
}
.logo-divider {
  width: 1px;
  height: 28px;
  background: var(--border);
}
.logo-text {
  font-size: 0.65rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  line-height: 1.4;
  font-weight: 500;
}
nav {
  display: flex;
  align-items: center;
  gap: 0;
}
nav a {
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  transition: all var(--transition);
}
nav a:hover {
  color: var(--accent);
  background: var(--accent-light);
}
nav a.active {
  color: var(--accent);
  font-weight: 600;
}
nav .nav-cta {
  background: var(--accent);
  color: var(--white);
  padding: 0.6rem 1.5rem;
  border-radius: 50px;
  margin-left: 0.5rem;
  font-weight: 600;
}
nav .nav-cta:hover {
  background: var(--accent-hover);
  color: var(--white);
}

/* Mobile menu */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}
.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--dark);
  margin: 5px 0;
  transition: 0.3s;
  border-radius: 2px;
}

/* ---- Hero ---- */
.hero {
  position: relative;
  background: var(--bg-light);
  overflow: hidden;
}
.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 540px;
  align-items: center;
  gap: 3rem;
}
.hero-content {
  padding: 4rem 0;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent-light);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.4rem 1rem;
  border-radius: 50px;
  margin-bottom: 1.5rem;
}
.hero-badge svg {
  width: 14px;
  height: 14px;
}
.hero h1 {
  margin-bottom: 1.2rem;
}
.hero-text {
  color: var(--text-light);
  font-size: 1.05rem;
  max-width: 480px;
  margin-bottom: 2rem;
  line-height: 1.8;
}
.hero-image {
  position: relative;
  height: 100%;
  min-height: 400px;
  background: linear-gradient(135deg, var(--dark) 0%, #2D4A5E 100%);
  border-radius: 0 0 0 var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.hero-image-text {
  font-size: 8rem;
  font-weight: 800;
  color: rgba(255,255,255,0.08);
  letter-spacing: -0.02em;
  line-height: 1;
  position: absolute;
}
.hero-image-badge {
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  color: var(--white);
  padding: 1.5rem 2rem;
  border-radius: var(--radius);
  text-align: center;
  position: relative;
  z-index: 1;
}
.hero-image-badge .badge-number {
  font-size: 2.4rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.3rem;
}
.hero-image-badge .badge-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.85;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0.85rem 1.8rem;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}
.btn svg {
  width: 16px;
  height: 16px;
  transition: transform var(--transition);
}
.btn:hover svg {
  transform: translateX(3px);
}
.btn-primary {
  background: var(--accent);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 4px 16px rgba(27, 42, 61, 0.25);
}
.btn-secondary {
  background: var(--white);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.btn-ghost {
  background: transparent;
  color: var(--accent);
  padding: 0;
  font-weight: 600;
}
.btn-ghost:hover {
  color: var(--accent-hover);
}
.btn-white {
  background: var(--white);
  color: var(--accent);
}
.btn-white:hover {
  background: var(--bg-light);
}

/* ---- Sections ---- */
.section {
  padding: 5rem 2rem;
}
.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}
.section-header {
  margin-bottom: 3rem;
}
.section-header p {
  color: var(--text-light);
  font-size: 1.05rem;
  margin-top: 0.6rem;
}
.section-overline {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 0.6rem;
}
.section-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ---- Service Cards (stendi-style) ---- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.service-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition);
}
.service-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}
.service-card-image {
  height: 200px;
  background: linear-gradient(135deg, var(--dark) 0%, #4A5568 100%);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.service-card-image .service-icon-large {
  color: rgba(255,255,255,0.12);
  width: 80px;
  height: 80px;
}
.service-card-image .service-tag {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  background: var(--accent);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.service-card-body {
  padding: 1.5rem;
}
.service-card-body h3 {
  margin-bottom: 0.6rem;
}
.service-card-body p {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.7;
  margin-bottom: 1rem;
}
.service-card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.88rem;
  transition: gap var(--transition);
}
.service-card-link:hover {
  gap: 0.7rem;
}
.service-card-link svg {
  width: 16px;
  height: 16px;
}

/* ---- Feature Cards (flat, side by side) ---- */
.feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}
.feature-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  position: relative;
  transition: all var(--transition);
}
.feature-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.feature-card-number {
  font-size: 3.5rem;
  font-weight: 800;
  color: rgba(27, 42, 61, 0.08);
  line-height: 1;
  margin-bottom: 1rem;
}
.feature-card h3 {
  margin-bottom: 0.8rem;
}
.feature-card p {
  font-size: 0.92rem;
  color: var(--text-light);
  margin-bottom: 1.2rem;
}
.feature-card ul {
  list-style: none;
}
.feature-card ul li {
  font-size: 0.88rem;
  color: var(--text);
  padding: 0.35rem 0;
  padding-left: 1.4rem;
  position: relative;
}
.feature-card ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.75rem;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
}

/* ---- About Section ---- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.about-image-block {
  background: linear-gradient(135deg, var(--dark) 0%, #2D4A5E 100%);
  border-radius: var(--radius-lg);
  aspect-ratio: 4/3;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 2rem;
  overflow: hidden;
}
.about-image-block::before {
  content: 'MEAS';
  font-size: 10rem;
  font-weight: 800;
  color: rgba(255,255,255,0.06);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  letter-spacing: -0.02em;
}
.about-image-badge {
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  color: var(--white);
  padding: 1rem 1.5rem;
  border-radius: var(--radius);
  position: relative;
  z-index: 1;
}
.about-image-badge strong {
  display: block;
  font-size: 1rem;
}
.about-image-badge span {
  font-size: 0.78rem;
  opacity: 0.8;
}
.about-text .section-overline { margin-bottom: 0.6rem; }
.about-text h2 { margin-bottom: 1.2rem; }
.about-text p {
  color: var(--text-light);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}
.about-text p.lead {
  font-size: 1.05rem;
  color: var(--text);
}
.about-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}
.about-tag {
  background: var(--bg-card);
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 50px;
  border: 1px solid var(--border);
}

/* ---- Godkjenning Banner ---- */
.godkjenning-banner {
  background: var(--accent-light);
  border: 1px solid rgba(27, 42, 61, 0.15);
  border-radius: var(--radius-lg);
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-top: 2rem;
}
.godkjenning-icon {
  width: 44px;
  height: 44px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 700;
}
.godkjenning-text strong {
  display: block;
  font-size: 0.88rem;
  color: var(--dark);
}
.godkjenning-text span {
  font-size: 0.8rem;
  color: var(--text-light);
}

/* ---- CTA Section ---- */
.cta-section {
  background: var(--dark);
  padding: 4rem 2rem;
  border-radius: var(--radius-lg);
  margin: 0 2rem 5rem;
  max-width: calc(var(--max-width) - 4rem);
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}
.cta-section h2 {
  color: var(--white);
  margin-bottom: 0.8rem;
}
.cta-section p {
  color: rgba(255,255,255,0.8);
  margin: 0 auto 2rem;
  font-size: 1.05rem;
  max-width: 500px;
}
.cta-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---- Contact Page ---- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 3rem;
}
.contact-info-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
}
.contact-info-card h3 {
  margin-bottom: 0.5rem;
}
.contact-info-card > p {
  color: var(--text-light);
  font-size: 0.92rem;
  margin-bottom: 2rem;
}
.contact-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  align-items: flex-start;
}
.contact-item-icon {
  width: 40px;
  height: 40px;
  background: var(--accent-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--accent);
}
.contact-item-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.15rem;
  font-weight: 500;
}
.contact-item-value {
  font-size: 0.95rem;
  color: var(--dark);
  font-weight: 500;
}
.contact-separator {
  border: none;
  border-top: 1px solid var(--border);
  margin: 1.5rem 0;
}
.contact-form h2 {
  margin-bottom: 0.4rem;
}
.contact-form > p {
  color: var(--text-light);
  font-size: 0.92rem;
  margin-bottom: 2rem;
}
.form-fields {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.form-group label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text);
}
.form-group input,
.form-group textarea,
.form-group select {
  font-family: var(--font);
  font-size: 0.92rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(27, 42, 61, 0.1);
}
.form-group textarea {
  resize: vertical;
  min-height: 130px;
}

/* ---- Page Hero (subpages) ---- */
.page-hero {
  background: var(--bg-light);
  padding: calc(2.5rem) 2rem 2.5rem;
}
.page-hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}
.page-hero .section-overline { margin-bottom: 0.6rem; }
.page-hero h1 {
  margin-bottom: 0.6rem;
}
.page-hero p {
  color: var(--text-light);
  font-size: 1.05rem;
  max-width: 600px;
}
.breadcrumb {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
.breadcrumb a {
  color: var(--text-light);
  transition: color var(--transition);
}
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span { color: var(--text-muted); }

/* ---- Footer ---- */
.site-footer {
  background: var(--dark-footer);
  color: rgba(255,255,255,0.6);
  padding: 4rem 2rem 2rem;
}
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}
.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-brand .logo-mark {
  color: var(--white);
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 0.8rem;
}
.footer-brand p {
  font-size: 0.88rem;
  line-height: 1.7;
  max-width: 300px;
}
.footer-col h4 {
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}
.footer-col a {
  display: block;
  font-size: 0.88rem;
  margin-bottom: 0.5rem;
  transition: color var(--transition);
}
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1.5rem;
  font-size: 0.78rem;
}

/* ---- Process Steps ---- */
.process-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.process-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  transition: all var(--transition);
}
.process-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.process-number {
  width: 48px;
  height: 48px;
  background: var(--accent);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  margin: 0 auto 1.2rem;
}
.process-card h3 {
  margin-bottom: 0.6rem;
}
.process-card p {
  font-size: 0.9rem;
  color: var(--text-light);
  margin: 0 auto;
}

/* ---- Info Boxes ---- */
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.info-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: all var(--transition);
}
.info-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.info-card-icon {
  width: 44px;
  height: 44px;
  background: var(--accent-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.2rem;
  color: var(--accent);
}
.info-card h3 { margin-bottom: 0.5rem; }
.info-card p {
  font-size: 0.9rem;
  color: var(--text-light);
}

/* ---- Animations ---- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp 0.6s ease forwards; }
.delay-1 { animation-delay: 0.1s; opacity: 0; }
.delay-2 { animation-delay: 0.2s; opacity: 0; }
.delay-3 { animation-delay: 0.3s; opacity: 0; }

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; min-height: auto; }
  .hero-image { display: none; }
  .about-grid { grid-template-columns: 1fr; }
  .about-image-block { display: none; }
  .footer-top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  nav { display: none; }
  nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--white);
    padding: 1rem;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
  }
  nav.open a { padding: 0.7rem 1rem; }
  nav.open .nav-cta { text-align: center; margin-left: 0; margin-top: 0.5rem; }
  .menu-toggle { display: block; }
  .services-grid,
  .info-grid,
  .process-grid,
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .contact-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; gap: 2rem; }
  .cta-section { margin: 0 1rem 3rem; border-radius: var(--radius); }
  .section { padding: 3rem 1.5rem; }
}
