/* ================================================
   PROPTECH REDESIGN — lease-extensions.org.uk
   Load LAST in <head> to override previous styles
   ================================================ */

:root {
  --navy:       #0f172a;
  --slate:      #1e293b;
  --blue:       #3b82f6;
  --blue-dark:  #2563eb;
  --gray-bg:    #f8fafc;
  --border:     #e2e8f0;
  --text-body:  #475569;
  --text-muted: #94a3b8;
  --white:      #ffffff;
  --radius:     12px;
  --font:       'Plus Jakarta Sans', 'Inter', 'Hanken Grotesk', sans-serif;
}

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

body {
  font-family: var(--font);
  background-color: var(--gray-bg);
  color: var(--text-body);
  line-height: 1.6;
  font-size: 16px;
}

#main {
  background-color: var(--gray-bg);
  max-width: none;
}

/* ─────────────────────────────────────────────
   STICKY HEADER
───────────────────────────────────────────── */
.wrap-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

#header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 24px;
  background: none;
  height: auto;
}

/* Logo area */
#logo {
  display: flex;
  align-items: center;
  position: unset;
  height: auto;
  max-width: none;
  width: auto;
}

#logo #logo_text { position: unset; }

#logo_text h1,
#logo_text h1 a,
#logo_text h1 a:hover {
  font-family: var(--font);
  font-size: 19px;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.02em;
  padding: 0;
  text-decoration: none;
  border: none;
}

#logo_text h1 a .logo_colour { color: var(--blue); }

#logo_text h2 {
  font-family: var(--font);
  font-size: 12px;
  font-weight: 400;
  color: var(--text-muted);
  padding: 2px 0 0;
  margin: 0;
  border: none;
}

/* Navbar */
#menubar {
  background: none;
  max-width: none;
  margin-left: auto;
  padding: 0;
  overflow: visible;
}

ul#menu,
ul#menu li {
  float: none;
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
}

ul#menu li { list-style: none; }

ul#menu li a {
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  color: var(--slate);
  text-decoration: none;
  padding: 7px 14px;
  border-radius: 7px;
  line-height: 1.4;
  float: none;
  display: block;
  transition: background 0.14s, color 0.14s;
  text-transform: none;
  letter-spacing: 0;
}

ul#menu li a:hover { background: var(--gray-bg); color: var(--blue); }

ul#menu li.selected a,
ul#menu li.selected a:hover { background: none; color: var(--slate); }

/* CTA nav button */
ul#menu li.menu-cta a {
  background: var(--blue);
  color: var(--white);
  font-weight: 700;
  padding: 9px 18px;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(59, 130, 246, 0.28);
  text-decoration: none;
}

ul#menu li.menu-cta a:hover {
  background: var(--blue-dark);
  color: var(--white);
}

/* Mobile toggler */
.navbar-toggler {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  margin-left: 16px;
}

.navbar-toggler span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--slate);
  border-radius: 2px;
}

/* ─────────────────────────────────────────────
   HERO SECTION
───────────────────────────────────────────── */
.hero-section {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
  background: var(--navy);
}

.hero-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(15, 23, 42, 0.50) 0%,
    rgba(15, 23, 42, 0.80) 100%
  );
}

.hero-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 32px;
  max-width: 820px;
  margin: 0 auto;
  right: 0;
  left: 0;
}

.last-updated-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(59, 130, 246, 0.18);
  border: 1px solid rgba(59, 130, 246, 0.45);
  color: #93c5fd;
  font-family: var(--font);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}

.hero-content h1 {
  font-family: var(--font);
  font-size: clamp(1.75rem, 4.5vw, 2.6rem);
  font-weight: 800;
  color: var(--white);
  line-height: 1.18;
  margin: 0 0 14px;
  padding: 0;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
  border: none;
}

.hero-sub {
  color: #cbd5e1;
  font-family: var(--font);
  font-size: 1.05rem;
  line-height: 1.6;
  margin: 0 0 28px;
  padding: 0;
}

.hero-cta-btn {
  display: inline-block;
  background: var(--blue);
  color: var(--white);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 700;
  padding: 13px 30px;
  border-radius: 8px;
  text-decoration: none;
  letter-spacing: 0.01em;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.38);
  transition: background 0.14s, transform 0.14s;
}

.hero-cta-btn:hover {
  background: var(--blue-dark);
  transform: translateY(-2px);
  color: var(--white);
  text-decoration: none;
}

/* ─────────────────────────────────────────────
   SITE CONTENT LAYOUT
───────────────────────────────────────────── */
#site_content {
  display: flex;
  flex-direction: row;
  gap: 28px;
  max-width: 1200px;
  margin: 32px auto;
  padding: 0 24px 48px;
  background: transparent;
  overflow: visible;
}

#site_content .sidebar {
  order: 2;
  width: 280px;
  min-width: 280px;
  flex-shrink: 0;
  float: none;
  padding: 0;
}

#content {
  order: 1;
  flex: 1;
  min-width: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px 44px;
  width: auto;
}

/* ─────────────────────────────────────────────
   CONTENT TYPOGRAPHY
───────────────────────────────────────────── */
#content h1,
#content h2,
#content h3,
#content h4,
#content h5,
#content h6 {
  font-family: var(--font);
  font-weight: 700;
  color: var(--slate);
  line-height: 1.3;
}

#content h1 {
  font-size: 24px;
  color: var(--navy);
  margin: 0 0 20px;
  padding: 0 0 20px;
  border-bottom: 1px solid var(--border);
}

#content h2 {
  font-size: 20px;
  color: var(--slate);
  margin: 0 0 12px;
  padding: 0;
}

#content h3 { font-size: 17px; }

#content p {
  font-family: var(--font);
  font-size: 15.5px;
  line-height: 1.75;
  color: var(--text-body);
  margin: 0 0 20px;
  padding: 0;
}

#content a {
  color: var(--blue);
  text-decoration: underline;
  text-underline-offset: 2px;
  outline: none;
}

#content a:hover { color: var(--blue-dark); text-decoration: none; }

#content ul { margin: 0 0 20px; }

#content ul li {
  font-size: 15.5px;
  line-height: 1.7;
  color: var(--text-body);
  padding: 0 0 6px;
  background: none;
}

/* Section separator */
#content .border-top {
  border-top: 1px solid var(--border) !important;
  padding-top: 28px !important;
  margin-top: 28px !important;
}

/* ─────────────────────────────────────────────
   AUTHOR CARD
───────────────────────────────────────────── */
.author-snippet {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 8px;
  transition: box-shadow 0.2s, transform 0.2s;
}

.author-snippet:hover {
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.07);
  transform: translateY(-2px);
}

.author-snippet .author-image {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--border);
  object-fit: cover;
  margin: 0;
}

.author-snippet .author-info p {
  padding: 0;
  margin: 0;
  line-height: 1.5;
}

.author-snippet .author-link {
  font-weight: 700;
  font-size: 14px;
  color: var(--navy);
  text-decoration: none;
}

.author-snippet .author-link:hover { color: var(--blue); }

.author-snippet .author-description {
  font-size: 13px;
  color: var(--text-muted);
}

/* Back-link badge — hidden on homepage */
.badge.badge-primary-soft { display: none; }

/* ─────────────────────────────────────────────
   SIDEBAR — SHARED CARD WRAPPER
───────────────────────────────────────────── */
.sidebar-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 18px;
  margin-bottom: 14px;
  transition: box-shadow 0.2s, transform 0.2s;
}

.sidebar-card:hover {
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
  transform: translateY(-1px);
}

.sidebar-card-title {
  font-family: var(--font);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #94a3b8;
  margin: 0 0 18px;
  padding: 0;
}

/* Remove old h3 styles within sidebar */
.sidebar h3 {
  font-family: var(--font);
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--text-muted);
  margin: 0;
  padding: 0;
}

/* ─────────────────────────────────────────────
   SIDEBAR — STEPPER / TIMELINE
───────────────────────────────────────────── */
.stepper {
  position: relative;
  padding-left: 2px;
}

.stepper-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  position: relative;
  padding: 2px 0 12px;
}

/* Vertical connecting line */
.stepper-item:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 15px;
  top: 30px;
  bottom: -2px;
  width: 1px;
  background: linear-gradient(to bottom, rgba(59, 130, 246, 0.35), rgba(226, 232, 240, 1));
  border-radius: 999px;
}

.stepper-icon {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: linear-gradient(180deg, #5b8ef7 0%, var(--blue) 100%);
  color: var(--white);
  font-family: var(--font);
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 0 5px rgba(59, 130, 246, 0.08), 0 10px 18px rgba(59, 130, 246, 0.12);
}

.stepper-item:nth-child(1) .stepper-icon { background: linear-gradient(180deg, #dbeafe 0%, #93c5fd 100%); }
.stepper-item:nth-child(2) .stepper-icon { background: linear-gradient(180deg, #c6ddff 0%, #7fb3fb 100%); }
.stepper-item:nth-child(3) .stepper-icon { background: linear-gradient(180deg, #b2d0ff 0%, #69a4fa 100%); }
.stepper-item:nth-child(4) .stepper-icon { background: linear-gradient(180deg, #9dc2ff 0%, #5894f8 100%); }
.stepper-item:nth-child(5) .stepper-icon { background: linear-gradient(180deg, #89b4ff 0%, #4a86f5 100%); }
.stepper-item:nth-child(6) .stepper-icon { background: linear-gradient(180deg, #74a6fb 0%, #3f79f2 100%); }
.stepper-item:nth-child(7) .stepper-icon { background: linear-gradient(180deg, #5e96f7 0%, #346aed 100%); }
.stepper-item:nth-child(8) .stepper-icon { background: linear-gradient(180deg, #4a87f0 0%, #2d5fdf 100%); }
.stepper-item:nth-child(9) .stepper-icon { background: linear-gradient(180deg, #3b82f6 0%, #1e40af 100%); }

.stepper-label {
  display: flex;
  align-items: center;
  min-height: 30px;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  color: var(--slate);
  text-decoration: none;
  line-height: 1.35;
  padding: 2px 0 0;
  transition: color 0.16s ease, transform 0.16s ease;
}

.stepper-label:hover {
  color: var(--blue);
  text-decoration: none;
  transform: translateX(2px);
}

.stepper-item:first-child .stepper-label {
  color: var(--blue-dark);
}

.stepper-item:first-child .stepper-icon {
  box-shadow: 0 0 0 6px rgba(59, 130, 246, 0.12), 0 12px 22px rgba(59, 130, 246, 0.16);
}

.stepper-item:last-child {
  padding-bottom: 0;
}

/* ─────────────────────────────────────────────
   SIDEBAR — LATEST NEWS
───────────────────────────────────────────── */
.news-title {
  font-family: var(--font);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--slate);
  margin: 0 0 10px;
  padding: 0;
  line-height: 1.4;
}

.latest-news-p {
  font-family: var(--font);
  font-size: 13px;
  color: var(--text-body);
  margin: 0 0 10px;
  padding: 0;
  line-height: 1.55;
}

.latest-news-p a {
  color: var(--blue);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ─────────────────────────────────────────────
   SIDEBAR — HELPFUL LINKS
───────────────────────────────────────────── */
.sidebar ul {
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
}

.sidebar li {
  padding: 0;
  border-bottom: 1px solid var(--border);
  list-style: none;
}

.sidebar li:last-child { border-bottom: none; }

.sidebar li a,
.sidebar li a:visited,
.sidebar li a:hover,
.sidebar ul li a,
.sidebar ul li a:hover {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  width: 100% !important;
  min-height: 46px !important;
  padding: 12px 14px !important;
  margin: 0 !important;
  border-radius: 10px !important;
  font-family: var(--font) !important;
  font-size: 15px !important;
  font-weight: 500 !important;
  line-height: 1.5 !important;
  color: var(--text-body) !important;
  text-decoration: none !important;
  background: var(--white) !important;
  border: 1px solid transparent !important;
  box-sizing: border-box !important;
  transition: background-color 0.16s ease, color 0.16s ease !important;
}

.sidebar li a:hover,
.sidebar ul li a:hover {
  color: var(--navy) !important;
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.12), rgba(59, 130, 246, 0.04)) !important;
  font-size: 15px !important;
  font-weight: 500 !important;
}

.sidebar li a::before {
  content: '' !important;
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background: rgba(59, 130, 246, 0.35) !important;
  flex: 0 0 8px !important;
}

.sidebar li a:hover::before {
  background: var(--blue) !important;
}

/* ─────────────────────────────────────────────
   FOOTER
───────────────────────────────────────────── */
#footer {
  background: var(--navy);
  color: #94a3b8;
  padding: 0;
  line-height: 1.6;
  letter-spacing: 0;
  width: 100%;
}

.footer {
  width: 100%;
  margin: 0 auto;
  padding: 56px 0 40px;
  background: var(--navy);
}

.footer > * {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.footer-inner {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
  margin-bottom: 40px;
  align-items: flex-start;
}

.footer-col { flex: 1 1 180px; min-width: 160px; }

.footer-col h6 {
  font-family: var(--font);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #64748b;
  padding: 0 0 14px;
  margin: 0 0 14px;
  border-bottom: 1px solid #1e293b;
}

.footer-col ul { margin: 0; padding: 0; list-style: none; }
.footer-col li { padding: 0; list-style: none; }

.footer-col a,
.footer-col a:visited,
.footer-col a:hover,
.footer-inner ul a,
.footer-inner ul a:hover,
#footer a,
#footer a:hover {
  font-family: var(--font) !important;
  font-size: 13.5px !important;
  font-weight: 400 !important;
  color: #93a4c3 !important;
  text-decoration: none !important;
  line-height: 2.1 !important;
  display: inline-block;
  transition: color 0.14s;
}

.footer-col a:hover,
.footer-inner ul a:hover,
#footer a:hover {
  color: #ffffff !important;
}

.footer .copyright,
.footer p.copyright {
  font-family: var(--font);
  font-size: 12px;
  color: #94a3b8;
  line-height: 1.7;
  border-top: 1px solid #1e293b;
  padding-top: 24px;
  margin-top: 0;
}

/* ─────────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────────── */
@media (max-width: 960px) {
  #site_content {
    flex-direction: column;
    margin-top: 20px;
    padding: 0 16px 32px;
    gap: 16px;
  }

  #site_content .sidebar {
    order: 2;
    width: 100%;
    min-width: 0;
  }

  #content {
    padding: 28px 24px;
    width: 100%;
  }

  .hero-section { height: 320px; }

  .footer-inner { gap: 28px; }
}

@media (max-width: 640px) {
  #header { padding: 12px 16px; }

  .navbar-toggler { display: flex; }

  ul#menu { display: none; }

  .hero-section { height: 270px; }

  .hero-content h1 { font-size: 1.5rem; }

  #content { padding: 22px 18px; }
}
