/* ============================================================
   WATER CHANNEL — by Rispri Labs
   Self-contained stylesheet (deployed as its own subdomain/project,
   so it cannot depend on ../styles.css). Palette intentionally
   mirrors the main Rispri Labs site for brand consistency.
   ============================================================ */

:root {
  --primary:       #013a6e;
  --primary-dark:  #012550;
  --primary-mid:   #1b5ea0;
  --primary-light: #e8f2fb;
  --accent:        #e87722;
  --accent-dark:   #c4611a;
  --accent-light:  #fef3e8;
  --teal:          #00818a;
  --teal-light:    #e3f5f6;

  --white:   #ffffff;
  --off-white: #f8fafb;
  --gray-50: #f4f7fc;
  --gray-100: #eef2f7;
  --gray-200: #dce4ec;
  --gray-400: #8fa1b4;
  --gray-600: #5a6e7f;
  --text:    #1a2c3d;

  --shadow-xs: 0 1px 4px rgba(1,58,110,0.07);
  --shadow-sm: 0 4px 14px rgba(1,58,110,0.10);
  --shadow:    0 8px 28px rgba(1,58,110,0.13);

  --radius-sm: 6px;
  --radius:    10px;
  --radius-lg: 14px;
  --radius-xl: 20px;

  /* category colors */
  --cat-regulation: #013a6e;
  --cat-innovation: #00818a;
  --cat-research:   #6b3fa0;
  --cat-conservation: #1a8a4c;
  --cat-industry:   #e87722;
}

* , *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
html, body { overflow-x: hidden; }

body {
  font-family: "Inter", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--off-white);
}

h1, h2, h3, h4 { font-family: "Barlow", "Inter", sans-serif; line-height: 1.15; }

a { color: inherit; }
img { max-width: 100%; display: block; }

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

/* ── Header ─────────────────────────────────────────────── */
.wc-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-100);
  position: sticky;
  top: 0;
  z-index: 100;
}

.wc-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.5rem;
  max-width: 1180px;
  margin: 0 auto;
  gap: 1rem;
  flex-wrap: wrap;
}

.wc-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
}

.wc-brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-family: "Barlow", sans-serif;
  font-weight: 800;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.wc-brand-text strong {
  display: block;
  font-family: "Barlow", sans-serif;
  font-weight: 800;
  color: var(--primary-dark);
  font-size: 1.05rem;
  line-height: 1.2;
}

.wc-brand-text span {
  display: block;
  font-size: 0.72rem;
  color: var(--gray-600);
  letter-spacing: 0.03em;
}

.wc-header-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  border: 1px solid var(--gray-200);
  border-radius: 999px;
  padding: 0.5rem 1rem;
  transition: background 0.15s, border-color 0.15s;
}

.wc-header-cta:hover { background: var(--primary-light); border-color: var(--primary); }

/* ── Hero ───────────────────────────────────────────────── */
.wc-hero {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 55%, #015570 100%);
  padding: clamp(2.4rem, 5vw, 4rem) 0 clamp(2rem, 4vw, 3rem);
  position: relative;
  overflow: hidden;
}

.wc-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 100% 0%, rgba(232,119,34,0.16), transparent 60%),
    radial-gradient(ellipse at 0% 100%, rgba(0,129,138,0.16), transparent 60%);
}

.wc-hero-inner { position: relative; z-index: 1; }

.wc-overline {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 999px;
  padding: 0.3rem 0.9rem;
  margin-bottom: 1rem;
}

.wc-hero h1 {
  color: var(--white);
  font-size: clamp(1.9rem, 4vw, 2.8rem);
  font-weight: 800;
  max-width: 20ch;
  margin-bottom: 0.9rem;
}

.wc-hero p {
  color: rgba(255,255,255,0.8);
  font-size: clamp(0.95rem, 1.3vw, 1.05rem);
  max-width: 62ch;
  margin-bottom: 1.6rem;
}

.wc-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.wc-hero-meta span {
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(255,255,255,0.85);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 999px;
  padding: 0.35rem 0.85rem;
}

/* ── Section shell ──────────────────────────────────────── */
.wc-section { padding: clamp(2rem, 4vw, 3rem) 0; }
.wc-section-head { margin-bottom: 1.5rem; }
.wc-section-head h2 {
  font-size: clamp(1.3rem, 2.2vw, 1.7rem);
  color: var(--primary-dark);
  margin-bottom: 0.4rem;
}
.wc-section-head p { color: var(--gray-600); font-size: 0.92rem; max-width: 70ch; }

/* ── Dashboard ──────────────────────────────────────────── */
.wc-dashboard {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 1.2rem;
}

.wc-panel {
  background: var(--white);
  border: 1px solid var(--gray-100);
  border-radius: var(--radius-lg);
  padding: 1.4rem;
  box-shadow: var(--shadow-xs);
}

.wc-panel h3 {
  font-size: 0.95rem;
  color: var(--primary-dark);
  margin-bottom: 1rem;
}

.wc-bar-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 0.7rem;
}

.wc-bar-label {
  width: 110px;
  flex-shrink: 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--gray-600);
}

.wc-bar-track {
  flex: 1;
  height: 10px;
  background: var(--gray-100);
  border-radius: 999px;
  overflow: hidden;
}

.wc-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.6s ease;
}

.wc-bar-count {
  width: 22px;
  flex-shrink: 0;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--primary-dark);
  text-align: right;
}

.wc-tagcloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.wc-tag-pill {
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--primary-mid);
  background: var(--primary-light);
  border-radius: 999px;
  padding: 0.3rem 0.75rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s;
}

.wc-tag-pill:hover { border-color: var(--primary-mid); }
.wc-tag-pill.active { background: var(--primary); color: var(--white); }

/* ── Filter bar ─────────────────────────────────────────── */
.wc-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin: 1.6rem 0 1.6rem;
}

.wc-search {
  flex: 1;
  min-width: 200px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 0.7rem 1rem;
  font: inherit;
  font-size: 0.88rem;
  background: var(--white);
}

.wc-search:focus { outline: none; border-color: var(--primary-mid); box-shadow: 0 0 0 3px rgba(27,94,160,0.1); }

.wc-cat-btn {
  border: 1px solid var(--gray-200);
  background: var(--white);
  color: var(--text);
  border-radius: 999px;
  padding: 0.55rem 1rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  white-space: nowrap;
}

.wc-cat-btn.active { background: var(--primary); border-color: var(--primary); color: var(--white); }
.wc-cat-btn:not(.active):hover { background: var(--primary-light); border-color: var(--primary); }

.wc-result-count { font-size: 0.82rem; color: var(--gray-600); margin-bottom: 1rem; }

/* ── Insight cards ──────────────────────────────────────── */
.wc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.1rem;
}

.wc-card {
  background: var(--white);
  border: 1px solid var(--gray-100);
  border-radius: var(--radius-lg);
  padding: 1.3rem;
  box-shadow: var(--shadow-xs);
  transition: box-shadow 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
}

.wc-card:hover { box-shadow: var(--shadow-sm); transform: translateY(-2px); }

.wc-card-cat {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  margin-bottom: 0.7rem;
}

.wc-card-cat::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.wc-card-cat--regulation   { color: var(--cat-regulation);   background: #e8f2fb; }
.wc-card-cat--innovation   { color: var(--cat-innovation);   background: var(--teal-light); }
.wc-card-cat--research     { color: var(--cat-research);     background: #f0e9f8; }
.wc-card-cat--conservation { color: var(--cat-conservation); background: #e6f5eb; }
.wc-card-cat--industry     { color: var(--cat-industry);     background: var(--accent-light); }

.wc-card h4 {
  font-size: 1rem;
  color: var(--primary-dark);
  margin-bottom: 0.55rem;
  line-height: 1.35;
}

.wc-card p {
  font-size: 0.85rem;
  color: var(--gray-600);
  margin-bottom: 0.7rem;
  line-height: 1.55;
}

.wc-card-why {
  background: var(--gray-50);
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.85rem;
  font-size: 0.8rem;
  color: var(--text);
  margin-bottom: 0.9rem;
}

.wc-card-why strong { color: var(--primary-dark); }

.wc-card-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--gray-100);
}

.wc-card-source {
  font-size: 0.76rem;
  color: var(--primary-mid);
  text-decoration: none;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.wc-card-source:hover { text-decoration: underline; }

.wc-card-date { font-size: 0.72rem; color: var(--gray-400); white-space: nowrap; }

.wc-empty {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--gray-600);
  font-size: 0.9rem;
}

/* ── Footer ─────────────────────────────────────────────── */
.wc-footer {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.75);
  padding: 2rem 0;
  margin-top: 2rem;
}

.wc-footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.82rem;
}

.wc-footer a { color: var(--white); text-decoration: none; font-weight: 600; }
.wc-footer a:hover { text-decoration: underline; }

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 760px) {
  .wc-dashboard { grid-template-columns: 1fr; }
  .wc-bar-label { width: 90px; }
}
