/* Mayside Partners — One‑page template */
:root{
  --bg:#0b1d3a;
  --ink:#0c0e12;
  --muted:#6b7280;
  --card:#ffffff;
  --accent:#1e3a8a;
  --brand:#0a53ff;
  --ring:rgba(10,83,255,.25);
  --grid:clamp(16rem, 50vw, 22rem);
}
*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,'Helvetica Neue',Arial,sans-serif;line-height:1.6;color:var(--ink);background:#f6f8fb}
.container{max-width:1100px;margin:0 auto;padding:0 1.25rem}
h1,h2,h3,h4{line-height:1.2;margin:0 0 .5rem}
p{margin:.5rem 0 1rem}
.muted{color:var(--muted)}
.small{font-size:.9rem}

/* Header */
.site-header{position:sticky;top:0;z-index:50;background:#fff;border-bottom:1px solid #e5e7eb}
.header-inner{display:flex;align-items:center;justify-content:space-between;padding:.75rem 0}
.brand{display:flex;gap:.75rem;align-items:center}
.brand img{width:44px;height:44px;border-radius:.5rem}
.brand-text h1{font-size:1.25rem;margin:0}
.brand-text p{margin:0;color:var(--muted);font-weight:600;font-size:.9rem;letter-spacing:.06em}
.nav{display:flex;gap:1rem;align-items:center}
.nav a{color:var(--ink);text-decoration:none;font-weight:600;opacity:.9}
.nav a:hover{opacity:1}
.menu-toggle{display:none;background:none;border:none;font-size:1.5rem}

/* Hero */
.hero{background:linear-gradient(135deg,#0b1d3a,#1745a3);color:#fff;padding:4.5rem 0 3.5rem;margin-bottom:1.5rem}
.hero h2{font-size:clamp(1.75rem,3.2vw,2.5rem);max-width:48ch}
.hero p{max-width:60ch;opacity:.95}
.btn{display:inline-block;background:#fff;color:#0b1d3a;border:1px solid #e5e7eb;padding:.7rem 1rem;border-radius:.75rem;font-weight:700;text-decoration:none}
.btn:hover{box-shadow:0 2px 8px rgba(0,0,0,.08)}

/* Sections */
.section{padding:2.25rem 0}
.section.alt{background:#eef2ff}
.narrow{max-width:800px;margin:0 auto}
.ticks{list-style:none;padding:0;margin:1rem 0}
.ticks li{padding-left:1.5rem;position:relative;margin:.4rem 0}
.ticks li:before{content:'✓';position:absolute;left:0;top:.1rem;color:var(--brand);font-weight:900}

/* Cards & details */
.card{background:var(--card);border:1px solid #e5e7eb;border-radius:1rem;padding:1rem;margin:.75rem 0;box-shadow:0 2px 6px rgba(2,8,23,.04)}
.card.expand > summary{list-style:none;cursor:pointer}
.card.expand > summary::-webkit-details-marker{display:none}
.card.expand[open]{border-color:#c7d2fe;box-shadow:0 4px 16px rgba(30,58,138,.08)}
.card .content{padding-top:.5rem}

.accordion-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(var(--grid),1fr));gap:1rem;margin-top:.75rem}
.project-header{display:flex;justify-content:space-between;align-items:center;gap:1rem}
.pill{background:#e0e7ff;color:#1e3a8a;padding:.2rem .5rem;border-radius:999px;font-size:.8rem;font-weight:700}
.project-body{padding-top:.5rem}
.project-meta{display:flex;gap:1rem;align-items:flex-start}
.project-logo{width:60px;height:60px;border-radius:.6rem;border:1px solid #e5e7eb;object-fit:cover}
.links a{margin-right:.75rem;text-decoration:none;font-weight:700;color:var(--accent)}
.links a:hover{text-decoration:underline}

/* Tabs */
.tabs{display:flex;gap:.5rem;margin:1rem 0}
.tab{background:#eef2ff;border:1px solid #c7d2fe;color:#1e3a8a;border-radius:.75rem;padding:.5rem .9rem;font-weight:700;cursor:pointer}
.tab.active{background:#1e3a8a;color:#fff}
.tab-panel{display:none}
.tab-panel.active{display:block}

/* Forms */
.form{display:flex;flex-direction:column;gap:.8rem}
.grid{display:grid;grid-template-columns:1fr 1fr;gap:.8rem}
label{display:flex;flex-direction:column;font-weight:700;font-size:.95rem;gap:.35rem}
input,textarea{padding:.7rem .8rem;border-radius:.6rem;border:1px solid #d1d5db;font:inherit}
input:focus,textarea:focus{outline:2px solid var(--ring);border-color:#94a3b8}
textarea{resize:vertical}

/* Footer */
.site-footer{background:#0b1d3a;color:#cbd5e1;margin-top:2rem}
.footer-inner{display:flex;align-items:center;justify-content:space-between;padding:1rem 0}
.back-to-top{color:#cbd5e1;text-decoration:none;border:1px solid rgba(255,255,255,.3);padding:.4rem .6rem;border-radius:.5rem}
.back-to-top:hover{background:rgba(255,255,255,.12)}

/* Responsive */
@media (max-width: 840px){
  .nav{display:none}
  .menu-toggle{display:block}
  .grid{grid-template-columns:1fr}
}

@media (max-width: 840px){
  .nav{display:none}
  .menu-toggle{display:block}
  .grid{grid-template-columns:1fr}

  /* Mobile dropdown panel */
  #siteNav{
    position:fixed;
    top:60px; /* header height */
    left:0;
    right:0;
    background:#fff;
    border-bottom:1px solid #e5e7eb;
    box-shadow:0 6px 16px rgba(2,8,23,.08);
    flex-direction:column;
    align-items:flex-start;
    gap:.75rem;
    padding:.9rem 1.25rem 1.25rem;
    z-index:40;
  }
  #siteNav.open{display:flex}
  #siteNav a{padding:.25rem 0;font-size:1.05rem}
}


/* Alerts */
.form-alert{margin:.5rem 0 1rem;padding:.65rem .9rem;border-radius:.6rem;display:none}
.form-alert.show{display:block}
.form-alert.success{background:#ecfdf5;border:1px solid #34d399;color:#065f46}
.form-alert.error{background:#fef2f2;border:1px solid #fca5a5;color:#7f1d1d}
\n
/* Hero links: white text, underline on hover/focus (CTA button unaffected) */
.hero a{color:#fff;text-decoration:none}
.hero a:hover,
.hero a:focus{color:#fff;text-decoration:underline;text-underline-offset:.2em;text-decoration-thickness:2px}
.hero a.btn{color:#0b1d3a;text-decoration:none} /* keep button readable */
\n

\n
/* Footer links: white default; underline on hover/focus; visited forced white */
.site-footer a,
.site-footer a:link,
.site-footer a:visited{color:#ffffff;text-decoration:none}
.site-footer a:hover,
.site-footer a:focus{color:#ffffff;text-decoration:underline;text-underline-offset:.2em;text-decoration-thickness:2px}


/* Arrow alignment & behaviour for expandable cards */
.card.expand > summary{display:flex;align-items:center}
details.card.project > summary{display:flex;align-items:center;list-style:none;cursor:pointer}
details.card.project > summary::-webkit-details-marker{display:none}
details.card.project > summary::before{
  content:'▸';
  display:inline-block;
  margin-right:.5rem;
  font-size:1.25rem;
  line-height:1;
  transition:transform .18s ease;
}
details.card.project[open] > summary::before{transform:rotate(90deg)}

/* Floating back-to-top button (Mayside blue) */
.scroll-top{
  position:fixed;
  right:16px;
  bottom:16px;
  width:48px;
  height:48px;
  border-radius:999px;
  background:#1e3a8a;
  color:#fff;
  border:none;
  display:none;
  align-items:center;
  justify-content:center;
  font-size:20px;
  line-height:1;
  cursor:pointer;
  box-shadow:0 8px 24px rgba(2,8,23,.25);
  transition:opacity .2s ease, transform .2s ease;
  z-index:60;
}
.scroll-top.show{display:flex;opacity:1;transform:translateY(0)}
.scroll-top:focus{outline:3px solid rgba(10,83,255,.35);outline-offset:2px}
@media (prefers-reduced-motion:no-preference){
  .scroll-top{opacity:0;transform:translateY(8px)}
  .scroll-top.show{opacity:1;transform:translateY(0)}
}
