/* ============================================================
   HARTLEYS PROFESSIONAL TREE SURGEONS LTD  Design System
   Forest & Floral Theme
   ============================================================ */

:root {
  --forest:   #1a4a2e;
  --leaf:     #2e7d46;
  --sage:     #5a9e70;
  --bark:     #5c3d2e;
  --gold:     #b5883a;
  --moss:     #e8f2ea;
  --cream:    #f7f3ec;
  --white:    #ffffff;
  --text:     #1e2e22;
  --muted:    #4a6555;
  --radius:   14px;
  --shadow:   0 10px 30px rgba(26, 74, 46, 0.12);
}

/* Reset & Base */
* { box-sizing: border-box; }
html:focus-within { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--text);
  background-color: #0e2e1a;
  background-image: url("../Pictures%20and%20Videos/Background.jpeg");
  background-attachment: fixed;
  background-size: contain;
  background-position: center center;
  background-repeat: no-repeat;
  line-height: 1.6;
}

h1, h2, h3 { margin: 0 0 0.6rem; color: var(--forest); line-height: 1.2; }
h1, h2 { font-family: "Merriweather", Georgia, serif; }
p { margin: 0 0 1rem; }
a { color: var(--leaf); text-decoration: none; }
a:hover { text-decoration: underline; }

h2::before { content: " "; font-style: normal; }

/* Background pill behind standalone headings & text that sit over the background image */
.container > h1,
.container > h2,
.container > p,
.container > span.badge {
  background: rgba(247, 243, 236, 0.92);
  padding: 0.2em 0.75em;
  border-radius: 8px;
  display: inline-block;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

/* Catch headings one level deeper (e.g. inside .cat-header, .section-header etc.) */
.section:not(.surface) .container h1,
.section:not(.surface) .container h2 {
  background: rgba(247, 243, 236, 0.92);
  padding: 0.15em 0.7em;
  border-radius: 8px;
  display: inline-block;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

/* Strip pill from anything that already sits on its own background */
.card h1, .card h2, .card h3,
.hero-panel h1, .hero-panel h2,
[class*="-hero"] h1, [class*="-hero"] h2,
[class*="-hero"] p,
.surface .container h1, .surface .container h2,
.surface .container > h1, .surface .container > h2,
.surface .container > p, .surface .container > span.badge,
.modal-card h1, .modal-card h2,
.site-footer h1, .site-footer h2, .site-footer h3,
.site-footer p,
.pricing-box h1, .pricing-box h2,
.guarantee-box h1, .guarantee-box h2,
.after-card h1, .after-card h2,
.tl-card h1, .tl-card h2, .tl-card h3,
.promise-item h1, .promise-item h2,
.card h2, .card h3 {
  background: none;
  padding: 0;
  display: block;
  border-radius: 0;
}

/* High-specificity overrides for elements whose strip rule loses to .section:not(.surface) .container h2 */
.after-card h2,
.cta-banner h2,
.step-pane h2, .step-pane h3,
.hero-panel h1, .hero-panel h2 {
  background: none !important;
  padding: 0 !important;
  border-radius: 0 !important;
  display: block !important;
}

/* Remove pill inside sections that already have their own background */
.surface .container > h1,
.surface .container > h2,
.surface .container > p,
.surface .container > span.badge {
  background: none;
  padding: 0;
  border-radius: 0;
  display: block;
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--forest); color: var(--white); padding: 0.6rem 0.8rem;
}
.skip-link:focus { left: 0.5rem; top: 0.5rem; }

.container { width: min(1160px, 92%); margin: 0 auto; }
.section { padding: 4rem 0; }
.muted { color: var(--muted); }

.badge {
  display: inline-block;
  background: rgba(46, 125, 70, 0.12);
  color: var(--forest);
  border: 1px solid rgba(46, 125, 70, 0.3);
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
}

/*  HEADER  */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(247, 243, 236, 0.97);
  border-bottom: 3px solid rgba(46, 125, 70, 0.3);
  backdrop-filter: blur(10px);
}
.site-header.compact .utility-row { display: none; }
.header-row, .utility-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 0.65rem 0;
}
.brand {
  display: inline-flex; align-items: center; gap: 0.9rem;
  color: var(--forest); font-weight: 700;
}
.brand:hover { text-decoration: none; }
.brand-logo {
  /* Larger, wider logo frame for improved visibility */
  width: 320px;
  height: auto;
  max-height: 150px;
  object-fit: contain;
  border-radius: 10px;
  border: 5px solid var(--sage);
  padding: 8px;
  box-shadow: 0 12px 36px rgba(46, 125, 70, 0.38);
}
.brand-name { font-size: 1.05rem; line-height: 1.2; color: var(--forest); }
.nav-links { display: flex; gap: 1rem; flex-wrap: wrap; }
.nav-links a {
  color: var(--forest); font-weight: 600; font-size: 0.95rem;
  padding: 0.3rem 0.6rem; border-radius: 8px; transition: background 0.18s;
}
.nav-links a:hover { background: rgba(46, 125, 70, 0.1); text-decoration: none; }
.utility-row { border-top: 1px solid rgba(46, 125, 70, 0.15); padding-top: 0.55rem; }

/* -- Burger button -- */
.nav-burger {
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  width: 44px; height: 44px; flex-shrink: 0;
  background: none; border: none; cursor: pointer; padding: 8px; gap: 5px;
}
.nav-burger span {
  display: block; width: 22px; height: 2.5px;
  background: var(--forest); border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}
.nav-burger.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-burger.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* -- Nav drawer -- */
.nav-drawer {
  position: fixed; top: 0; left: 0; height: 100%; width: 280px;
  background: var(--cream); box-shadow: 4px 0 24px rgba(0,0,0,0.18);
  transform: translateX(-100%); transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
  z-index: 200; display: flex; flex-direction: column;
  padding: 1.2rem 1rem; gap: 0.2rem; overflow-y: auto;
}
.nav-drawer.open { transform: translateX(0); }
.drawer-close {
  align-self: flex-end; background: none; border: none; cursor: pointer;
  font-size: 1.6rem; color: var(--forest); padding: 0.1rem 0.5rem;
  line-height: 1; border-radius: 6px; transition: background 0.18s;
  margin-bottom: 0.8rem;
}
.drawer-close:hover { background: rgba(46,125,70,0.1); }
.nav-drawer a {
  color: var(--forest); font-weight: 600; font-size: 1.05rem;
  padding: 0.75rem 0.9rem; border-radius: 8px;
  text-decoration: none; transition: background 0.18s;
  border-bottom: 1px solid rgba(46,125,70,0.08);
}
.nav-drawer a:hover { background: rgba(46,125,70,0.1); text-decoration: none; }
.nav-drawer a:last-child { border-bottom: none; }
.nav-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,0.45); z-index: 199;
}
.nav-overlay.open { display: block; }

/* -- Header social icons -- */
.header-social { display: flex; gap: 0.5rem; align-items: center; margin-left: auto; }
.social-link {
  display: flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(46,125,70,0.1); color: var(--forest);
  transition: background 0.18s, color 0.18s; text-decoration: none; flex-shrink: 0;
}
.social-link:hover { background: var(--forest); color: var(--white); }
.social-link svg { pointer-events: none; }
.role-toggle {
  display: inline-flex;
  border: 2px solid rgba(46, 125, 70, 0.3); border-radius: 999px;
  overflow: hidden; background: var(--white);
}
.role-toggle button {
  border: 0; background: transparent; color: var(--forest);
  padding: 0.35rem 0.85rem; font-weight: 600; cursor: pointer; transition: background 0.18s;
}
.role-toggle button[aria-pressed="true"] { background: var(--forest); color: var(--white); }
.utility-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

/* Header phone badge (framed like the logo) */
.header-phone {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 8px 14px; font-weight: 700; color: var(--forest);
  background: var(--white); text-decoration: none;
  border: 4px solid var(--sage); border-radius: 12px;
  box-shadow: 0 8px 28px rgba(46,125,70,0.24);
}
.header-phone:hover { background: #f6fbf6; transform: translateY(-1px); }

@media (max-width: 720px) {
  .header-phone { padding: 6px 10px; font-size: 0.95rem; }
}

/*  BUTTONS  */
.btn, button.btn {
  border: 2px solid transparent; border-radius: 10px;
  padding: 0.62rem 1rem; font-weight: 700; font-size: 0.95rem;
  cursor: pointer; display: inline-block;
  transition: transform 0.18s, box-shadow 0.18s, background 0.18s;
}
.btn:hover { transform: translateY(-2px); text-decoration: none; }
.btn-primary { background: var(--forest); color: var(--white); border-color: var(--forest); }
.btn-primary:hover { background: #143d25; box-shadow: 0 6px 18px rgba(26,74,46,0.35); }
.btn-secondary { background: var(--white); color: var(--forest); border-color: var(--sage); }
.btn-secondary:hover { background: var(--moss); border-color: var(--leaf); }
.btn-accent { background: var(--leaf); color: var(--white); border-color: var(--leaf); }
.btn-accent:hover { background: #256639; box-shadow: 0 6px 18px rgba(46,125,70,0.35); }

/*  HERO  */
.hero {
  display: grid; grid-template-columns: 1.1fr 1fr;
  gap: 1.5rem; align-items: stretch; padding: 3rem 0 2rem;
}
.hero-panel {
  background: linear-gradient(160deg, var(--cream), var(--moss));
  border: 2px solid rgba(46, 125, 70, 0.2);
  border-radius: var(--radius); padding: 1.6rem;
  box-shadow: var(--shadow); position: relative; overflow: hidden;
}
.hero-panel::before {
  content: "";
  position: absolute; top: 10px; right: 14px;
  font-size: 3rem; opacity: 0.15; pointer-events: none;
}
.cta-row { display: flex; gap: 0.7rem; flex-wrap: wrap; margin: 1rem 0; }
.persona-band {
  display: inline-flex; gap: 0.4rem;
  background: rgba(46, 125, 70, 0.1); border-radius: 999px;
  padding: 0.3rem; margin-bottom: 0.8rem;
}
.persona-band button {
  border: 0; border-radius: 999px; padding: 0.4rem 0.8rem;
  cursor: pointer; background: transparent;
  color: var(--forest); font-weight: 600; transition: background 0.18s;
}
.persona-band button.active { background: var(--white); box-shadow: 0 2px 8px rgba(26,74,46,0.2); }

/* Tree ring animation */
.moa-visual { min-height: 280px; display: grid; place-items: center; position: relative; }
.moa-ring {
  width: 220px; height: 220px;
  border: 2px solid rgba(46, 125, 70, 0.35); border-radius: 50%;
  position: relative; animation: spin 18s linear infinite;
}
.moa-ring::before, .moa-ring::after {
  content: ""; position: absolute;
  border-radius: 50%;
}
.moa-ring::before { inset: 18px; border: 1px dashed rgba(26,74,46,0.25); }
.moa-ring::after  { inset: 40px; border: 1px solid rgba(90,158,112,0.2); }
.moa-node {
  position: absolute; width: 14px; height: 14px; border-radius: 50%;
  background: var(--leaf); top: -7px; left: calc(50% - 7px);
  box-shadow: 0 0 10px rgba(46,125,70,0.6);
}
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  html:focus-within { scroll-behavior: auto; }
  .moa-ring, .counter { animation: none !important; }
}

/* Responsive adjustments for header logo */
@media (max-width: 720px) {
  .brand-logo {
    width: 200px;
    max-height: 100px;
  }
  .header-row, .utility-row { padding: 0.45rem 0; }
}

/*  TRUST STRIP  */
.trust-strip {
  display: grid; grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 0.8rem; margin-top: 1.5rem;
}
.trust-item {
  background: var(--white); border: 2px solid rgba(46,125,70,0.18);
  border-radius: 12px; padding: 1rem; text-align: center;
}
.trust-item .trust-icon { font-size: 1.8rem; display: block; margin-bottom: 0.2rem; }
.counter { font-size: 1.6rem; font-weight: 700; color: var(--leaf); }

/*  CARDS & GRID  */
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 1.2rem; }
.card {
  background: var(--white); border: 2px solid rgba(46,125,70,0.15);
  border-radius: var(--radius); padding: 1.2rem;
  box-shadow: 0 2px 12px rgba(26,74,46,0.07); position: relative; overflow: hidden;
}
.card::after {
  content: ""; position: absolute; bottom: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--leaf), var(--sage)); opacity: 0; transition: opacity 0.2s;
}
.card:hover { transform: translateY(-3px); transition: transform 0.2s ease; }
.card:hover::after { opacity: 1; }

/*  PIPELINE SCROLLER  */
.pipeline-scroller { display: flex; gap: 1rem; overflow-x: auto; padding-bottom: 0.5rem; }
.pipeline-item { min-width: 290px; }
.stage { font-size: 0.82rem; color: var(--muted); font-weight: 500; }

/*  SURFACE / SECTION BACKGROUNDS  */
.surface {
  background: rgba(232, 242, 234, 0.82);
  backdrop-filter: blur(2px);
}

/* Homepage: make removed/remaining card text more professional and uniform
   Targets only the homepage sections adjusted above so global cards are unaffected */
#pipeline-preview .container > h2, #evidence-highlights .container > h2 {
  font-family: "Merriweather", Georgia, serif; font-weight: 700; letter-spacing: -0.5px;
  color: var(--forest); margin-bottom: 0.35rem;
}
#pipeline-preview p.muted, #evidence-highlights p.muted, #job-process p.muted {
  color: rgba(30,46,34,0.82); font-size: 0.98rem; max-width: 820px;
}
/* Ensure any cards in these sections (if added later) match sizes */
#pipeline-preview .card, #job-process .card, #evidence-highlights .card {
  min-height: 160px; padding: 1.25rem; display: flex; flex-direction: column; justify-content: center;
}
#pipeline-preview .card h3, #job-process .card h3, #evidence-highlights .card h3 {
  font-size: 1.05rem; font-weight: 700; color: var(--forest); margin-bottom: 0.45rem;
}
#pipeline-preview .card p, #job-process .card p, #evidence-highlights .card p {
  color: var(--muted); font-size: 0.95rem; margin: 0;
}

/*  MODAL  */
.modal {
  position: fixed; inset: 0; background: rgba(26,74,46,0.7);
  display: none; align-items: center; justify-content: center; z-index: 300;
}
.modal.open { display: flex; }
.modal-card {
  width: min(640px,92%); background: var(--white);
  border-radius: 16px; padding: 1.5rem;
  border-top: 6px solid var(--leaf);
  box-shadow: 0 20px 60px rgba(26,74,46,0.3);
}

/*  FORMS  */
form { display: grid; gap: 0.8rem; }
label { font-weight: 600; color: var(--forest); font-size: 0.94rem; }
input, select, textarea {
  width: 100%; border: 2px solid rgba(46,125,70,0.25);
  border-radius: 10px; padding: 0.6rem 0.8rem; font: inherit;
  transition: border-color 0.18s, box-shadow 0.18s;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--leaf);
  box-shadow: 0 0 0 3px rgba(46,125,70,0.12);
}
textarea { min-height: 100px; }
.inline-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem; }
.inline-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 0.8rem; }

/*  PAYMENT STEPS  */
.steps { display: flex; gap: 0.4rem; margin-bottom: 1rem; flex-wrap: wrap; }
.step-chip {
  border: 2px solid rgba(46,125,70,0.25); border-radius: 999px;
  padding: 0.35rem 0.8rem; color: var(--muted); font-weight: 600; font-size: 0.9rem;
}
.step-chip.active { background: var(--forest); color: var(--white); border-color: var(--forest); }
.step-pane { display: none; }
.step-pane.active { display: block; }
.pricing-box { border: 2px dashed rgba(46,125,70,0.3); border-radius: 12px; padding: 1rem; background: var(--moss); }

/*  TABLE  */
.table { width: 100%; border-collapse: collapse; }
.table th { background: var(--moss); color: var(--forest); font-weight: 700; border-bottom: 2px solid rgba(46,125,70,0.2); padding: 0.6rem; text-align: left; }
.table td { border-bottom: 1px solid rgba(46,125,70,0.12); padding: 0.55rem; text-align: left; }

/*  FOOTER  */
.site-footer {
  background: var(--forest); color: rgba(255,255,255,0.85);
  padding: 2.5rem 0 1.5rem; position: relative; overflow: hidden;
}
.site-footer h3 { color: var(--white); margin-bottom: 0.6rem; }
.site-footer h3::before { content: none; }
.site-footer a { color: rgba(143,208,139,0.9); }
.site-footer a:hover { color: var(--white); }
.footer-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1.5rem; }

/*  MISC  */
.small { font-size: 0.9rem; }
.notice {
  background: rgba(46,125,70,0.08); border-left: 4px solid var(--leaf);
  padding: 0.75rem 1rem; border-radius: 0 10px 10px 0; color: var(--forest);
}

/*  RESPONSIVE  */
@media (max-width: 920px) {
  .hero { grid-template-columns: 1fr; }
  .grid-3, .trust-strip, .footer-grid, .inline-3 { grid-template-columns: 1fr; }
  .inline-2 { grid-template-columns: 1fr; }
  .brand-logo { width: 64px; height: 64px; }
  .nav-links { gap: 0.6rem; }
  .nav-links a { font-size: 0.88rem; }
  .trust-strip { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 560px) {
  .trust-strip { grid-template-columns: 1fr; }
}
