/* Potens Instrumenta — Vanilla CSS */
:root {
  --bg: hsl(210 40% 98%);
  --fg: hsl(215 30% 12%);
  --muted: hsl(215 16% 46%);
  --card: hsl(0 0% 100%);
  --border: hsl(215 20% 90%);
  --secondary: hsl(28 95% 95%);
  --primary: hsl(14 85% 45%);
  --primary-glow: hsl(28 95% 55%);
  --accent: hsl(210 90% 35%);
  --sidebar-bg: hsl(215 35% 14%);
  --sidebar-fg: hsl(0 0% 100%);
  --sidebar-border: hsl(215 20% 25%);
  --shadow-elegant: 0 30px 60px -20px hsl(14 60% 25% / 0.35);
  --shadow-card: 0 12px 28px -12px hsl(215 30% 20% / 0.18);
  --gradient-hero: linear-gradient(135deg, hsl(28 95% 96%), hsl(14 80% 92%));
  --gradient-primary: linear-gradient(135deg, hsl(14 85% 45%), hsl(28 95% 55%));
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'DM Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { font-family: 'Space Grotesk', sans-serif; line-height: 1.1; margin: 0; }
p { margin: 0; }
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: transparent; color: inherit; }
ul { margin: 0; padding: 0; list-style: none; }

.container-x { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }

.badge-pill {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .35rem .75rem; border-radius: 999px;
  background: hsl(14 85% 45% / .1); color: var(--primary);
  font-size: .72rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
}

.btn-hero {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .85rem 1.4rem; border-radius: .75rem;
  background: var(--gradient-primary); color: #fff;
  font-weight: 600; font-size: .95rem;
  box-shadow: var(--shadow-elegant);
  transition: transform .2s ease, box-shadow .2s ease;
}
.btn-hero:hover { transform: translateY(-2px); }

.btn-ghost-primary {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .85rem 1.4rem; border-radius: .75rem;
  border: 1px solid var(--primary); color: var(--primary);
  font-weight: 600; font-size: .95rem;
  transition: background .2s ease, color .2s ease;
}
.btn-ghost-primary:hover { background: var(--primary); color: #fff; }

.disclaimer {
  display: flex; gap: .75rem; align-items: flex-start;
  padding: 1rem 1.25rem; border-radius: .75rem;
  background: hsl(210 90% 35% / .08); border-left: 4px solid var(--accent);
  font-size: .85rem; color: var(--fg);
}

.card-elevated {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 1.25rem; overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform .25s ease, box-shadow .25s ease;
}
.card-elevated:hover { transform: translateY(-4px); box-shadow: var(--shadow-elegant); }

/* Navbar */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  background: var(--primary); color: #fff;
  font-size: .8rem;
}
.topbar-inner { padding: .5rem 1.5rem; text-align: center; }
.topbar strong { font-weight: 600; }
.nav {
  position: fixed; top: 36px; left: 0; right: 0; z-index: 50;
  backdrop-filter: blur(10px); background: hsl(210 40% 98% / .85);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: baseline; gap: .25rem; font-size: 1.125rem; }
.brand .b1 { font-weight: 600; }
.brand .b2 { font-weight: 700; color: var(--primary); }
.brand .b3 { font-size: .85rem; color: var(--muted); margin-left: .35rem; }
.nav-links { display: none; gap: 2rem; }
.nav-links a { font-size: .9rem; color: var(--muted); transition: color .2s; }
.nav-links a:hover { color: var(--fg); }
.nav-toggle { display: inline-flex; padding: .5rem; }
.nav-mobile { display: none; flex-direction: column; gap: .25rem; padding: 0 1.5rem 1rem; }
.nav-mobile a { padding: .5rem 0; font-size: .9rem; color: var(--muted); }
.nav-mobile.open { display: flex; }
@media (min-width: 1024px) {
  .nav-links { display: flex; }
  .nav-toggle { display: none; }
  .brand .b3 { display: inline; }
}
@media (max-width: 640px) { .brand .b3 { display: none; } }

/* Hero */
.hero { background: var(--gradient-hero); padding: 8rem 0 5rem; }
.hero-grid { display: grid; gap: 3rem; align-items: center; }
@media (min-width: 1024px) { .hero-grid { grid-template-columns: 1fr 1fr; } }
.hero h1 {
  margin-top: 1.25rem;
  font-size: clamp(2.25rem, 4.5vw, 3.75rem); font-weight: 700;
}
.hero h1 .pri { color: var(--primary); }
.hero h1 .acc { color: var(--accent); }
.hero p.lead { margin-top: 1.5rem; max-width: 36rem; font-size: 1.05rem; color: var(--muted); }
.hero-ctas { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .75rem; }
.hero-disclaimer { margin-top: 2rem; }
.hero-img-wrap { position: relative; }
.hero-img-wrap .img-card {
  border-radius: 1.5rem; overflow: hidden; box-shadow: var(--shadow-elegant);
}
.hero-floating {
  position: absolute; left: -1.5rem; bottom: -1.5rem;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 1rem; padding: 1rem 1.25rem;
  box-shadow: 0 18px 30px -12px hsl(215 30% 20% / .25);
  display: none;
}
@media (min-width: 768px) { .hero-floating { display: block; } }
.hero-floating .lbl { font-size: .65rem; letter-spacing: .15em; text-transform: uppercase; color: var(--muted); }
.hero-floating .val { font-weight: 600; }
.hero-floating .sub { font-size: .75rem; color: var(--muted); }

/* Sections */
.section { padding: 6rem 0; }
.section.alt { background: hsl(28 95% 96% / .5); }
.section-head { max-width: 36rem; }
.section-head.center { margin: 0 auto; text-align: center; }
.section h2 { margin-top: 1rem; font-size: clamp(1.875rem, 3vw, 2.5rem); font-weight: 700; }
.section .sub { margin-top: 1rem; color: var(--muted); }

/* About */
.about-grid { display: grid; gap: 3rem; align-items: center; }
@media (min-width: 1024px) { .about-grid { grid-template-columns: 1fr 1fr; } }
.about-img { border-radius: 1.5rem; overflow: hidden; box-shadow: var(--shadow-card); }
.stats { margin-top: 2rem; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.stats .stat { border: 1px solid var(--border); background: var(--card); border-radius: .75rem; padding: 1rem; }
.stats .k { font-size: 1.5rem; font-weight: 700; color: var(--primary); }
.stats .v { font-size: .7rem; color: var(--muted); letter-spacing: .15em; text-transform: uppercase; margin-top: .25rem; }

/* Method / Categories grids */
.grid-3 { margin-top: 3rem; display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.grid-svc { margin-top: 3rem; display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .grid-svc { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid-svc { grid-template-columns: repeat(3, 1fr); } }

.card-elevated .body { padding: 1.5rem; }
.card-elevated .title-row { display: flex; align-items: center; gap: .75rem; }
.icon-chip { width: 44px; height: 44px; display: grid; place-items: center; border-radius: .6rem; background: hsl(14 85% 45% / .12); color: var(--primary); font-size: 1.4rem; }
.card-elevated h3 { font-size: 1rem; font-weight: 600; }
.card-elevated p { margin-top: .75rem; font-size: .875rem; color: var(--muted); }
.card-cover { aspect-ratio: 16/10; background: var(--gradient-hero); display: grid; place-items: center; font-size: 4rem; }

/* FAQ */
.faq-wrap { max-width: 720px; margin: 0 auto; }
.faq-card { background: var(--card); border: 1px solid var(--border); border-radius: 1.5rem; padding: 2.5rem; box-shadow: var(--shadow-card); }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-q { width: 100%; display: flex; justify-content: space-between; align-items: center; padding: 1rem 0; font-size: .9rem; font-weight: 500; text-align: left; transition: color .2s; }
.faq-q:hover { color: var(--primary); }
.faq-a { max-height: 0; overflow: hidden; opacity: 0; transition: max-height .3s ease, opacity .3s ease, padding .3s ease; font-size: .875rem; color: var(--muted); padding: 0; }
.faq-item.open .faq-a { max-height: 400px; opacity: 1; padding: 0 0 1rem; }
.faq-q .icon-plus, .faq-q .icon-minus { color: var(--muted); }
.faq-item .icon-minus { display: none; }
.faq-item.open .icon-plus { display: none; }
.faq-item.open .icon-minus { display: inline; }

/* Contact */
.contact-grid { display: grid; gap: 3rem; align-items: center; }
@media (min-width: 1024px) { .contact-grid { grid-template-columns: 1fr 1fr; } }
.contact-card { background: var(--card); border: 1px solid var(--border); border-radius: 1.5rem; padding: 2.5rem; box-shadow: var(--shadow-card); }
.contact-line { display: flex; align-items: center; gap: .75rem; font-size: .9rem; padding: .25rem 0; transition: color .2s; }
.contact-line:hover { color: var(--primary); }

/* Footer */
footer.foot { background: var(--sidebar-bg); color: var(--sidebar-fg); padding: 4rem 0 1.5rem; }
.foot-grid { display: grid; gap: 2.5rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .foot-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .foot-grid { grid-template-columns: repeat(5, 1fr); } }
.foot h4 { font-size: .875rem; font-weight: 600; margin-bottom: .75rem; display: flex; align-items: center; gap: .5rem; }
.foot h4::before { content: ""; width: 2px; height: 1rem; background: var(--primary-glow); border-radius: 999px; }
.foot ul li { padding: .25rem 0; font-size: .85rem; opacity: .7; }
.foot ul li a { transition: color .2s; }
.foot ul li a:hover { color: var(--primary-glow); }
.foot .small { font-size: .85rem; opacity: .7; }
.foot .brand-foot .b2 { color: var(--primary-glow); }
.foot .note {
  border-left: 4px solid var(--accent);
  background: hsl(0 0% 100% / .05);
  border-radius: .75rem; padding: 1rem; margin-top: 3rem;
}
.foot .note p { font-size: .75rem; opacity: .75; }
.foot .copy { font-size: .75rem; opacity: .5; text-align: center; margin-top: 1rem; padding-top: 1.5rem; border-top: 1px solid var(--sidebar-border); }

/* Legal pages */
.legal-header {
  position: sticky; top: 0; z-index: 40;
  background: hsl(210 40% 98% / .9); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.legal-header .inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.legal-back { display: inline-flex; align-items: center; gap: .35rem; color: var(--primary); font-weight: 500; font-size: .9rem; }
.legal-hero { padding: 4rem 0 2rem; }
.legal-hero .badge-pill { margin-bottom: 1rem; }
.legal-hero h1 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; }
.legal-hero .sub { margin-top: 1rem; color: var(--muted); font-size: 1.05rem; max-width: 42rem; }
.legal-hero .updated { margin-top: 1rem; font-size: .8rem; color: var(--muted); }
.legal-content { padding: 2rem 0 5rem; max-width: 760px; margin: 0 auto; }
.legal-content h2 { font-size: 1.25rem; font-weight: 700; margin-top: 2.5rem; margin-bottom: .75rem; color: var(--fg); }
.legal-content p { margin-bottom: 1rem; color: var(--muted); font-size: .95rem; }
.legal-content ul { list-style: disc; padding-left: 1.5rem; margin-bottom: 1rem; }
.legal-content ul li { color: var(--muted); margin-bottom: .5rem; font-size: .95rem; }
.legal-content a { color: var(--primary); text-decoration: underline; }
.legal-content strong { color: var(--fg); }

/* Institutional layout */
body.inst { font-family: 'DM Sans', system-ui, sans-serif; background: #f3f6fb; color: #0f1d33; margin: 0; min-height: 100vh; }
.inst .container-x { width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 1.25rem; }
.inst-header { background: linear-gradient(180deg, #0e2a4a 0%, #0a2140 100%); color: #fff; border-bottom: 3px solid #f4c343; }
.inst-header .inner { display: flex; align-items: center; justify-content: space-between; padding: 1.1rem 0; gap: 1rem; flex-wrap: wrap; }
.inst-brand h1 { font-family: 'Space Grotesk', sans-serif; font-size: 1.35rem; font-weight: 700; margin: 0; line-height: 1.1; }
.inst-brand .sub { font-size: .72rem; color: #c7d6ec; margin: .15rem 0 0; }
.inst-nav { display: flex; gap: 1.5rem; font-size: .9rem; }
.inst-nav a { color: #e5edf8; text-decoration: none; }
.inst-nav a:hover { color: #f4c343; }
.inst-hero { padding: 2.5rem 0 1rem; }
.inst-hero-card { background: linear-gradient(135deg, #0e2a4a 0%, #143769 100%); color: #fff; border-radius: 18px; padding: 2.5rem 2rem; box-shadow: 0 18px 40px -18px rgba(14,42,74,.35); position: relative; overflow: hidden; }
.inst-hero-card::after { content: ''; position: absolute; right: -60px; top: -60px; width: 220px; height: 220px; background: radial-gradient(circle, rgba(244,195,67,.18), transparent 70%); }
.inst-hero-card h2 { font-family: 'Space Grotesk', sans-serif; font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 700; margin: 0 0 1rem; line-height: 1.15; max-width: 38ch; }
.inst-hero-card p { color: #d4e1f4; font-size: 1rem; line-height: 1.6; max-width: 65ch; margin: 0; }
.inst-section { padding: 2rem 0; }
.inst-panel { background: #fff; border-radius: 18px; padding: 2rem; box-shadow: 0 8px 28px -18px rgba(14,42,74,.25); border-left: 4px solid #f4c343; }
.inst-panel + .inst-panel { margin-top: 1.5rem; }
.inst-panel h3 { font-family: 'Space Grotesk', sans-serif; font-size: 1.3rem; font-weight: 700; color: #0e2a4a; margin: 0 0 1.5rem; display: flex; align-items: center; gap: .55rem; }
.inst-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.inst-cell { background: #f5f8fd; border-left: 3px solid #f4c343; border-radius: 10px; padding: .9rem 1.1rem; }
.inst-cell .lbl { font-size: .78rem; font-weight: 700; color: #0e2a4a; margin: 0 0 .35rem; }
.inst-cell .val { font-size: .95rem; color: #1f3354; margin: 0; line-height: 1.4; word-break: break-word; }
.inst-cell .val.accent { color: #b88300; font-weight: 600; }
.inst-pill { display: inline-block; background: #1a8a4a; color: #fff; font-size: .68rem; font-weight: 700; padding: .15rem .5rem; border-radius: 4px; letter-spacing: .04em; }
.inst-services { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; }
.inst-svc { background: #f5f8fd; border-radius: 12px; padding: 1.25rem; border-top: 3px solid #f4c343; transition: transform .2s, box-shadow .2s; }
.inst-svc:hover { transform: translateY(-3px); box-shadow: 0 12px 24px -16px rgba(14,42,74,.3); }
.inst-svc .ico { font-size: 1.8rem; margin-bottom: .6rem; display: block; }
.inst-svc h4 { font-family: 'Space Grotesk', sans-serif; font-size: 1rem; font-weight: 600; color: #0e2a4a; margin: 0 0 .4rem; }
.inst-svc p { font-size: .85rem; color: #3d567a; margin: 0; line-height: 1.45; }
.inst-contact { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.25rem; }
.inst-contact .item { display: flex; flex-direction: column; gap: .3rem; }
.inst-contact .item .lbl { font-size: .78rem; font-weight: 700; color: #0e2a4a; }
.inst-contact .item a, .inst-contact .item span { color: #1f3354; font-size: .95rem; text-decoration: none; }
.inst-contact .item a:hover { color: #b88300; }
.inst-cta { display: inline-flex; align-items: center; gap: .5rem; background: #f4c343; color: #0e2a4a; font-weight: 700; padding: .75rem 1.4rem; border-radius: 8px; text-decoration: none; margin-top: 1rem; }
.inst-cta:hover { background: #e6b32f; }
.inst-foot { background: #0a2140; color: #c7d6ec; padding: 2rem 0; margin-top: 2rem; font-size: .85rem; text-align: center; }
.inst-foot p { margin: .25rem 0; }
.inst-foot a { color: #f4c343; text-decoration: none; }
.inst-note { font-size: .8rem; color: #5a7497; text-align: center; padding: 1rem 0; font-style: italic; }
