/* Rubber Duck as a Service — a demo skin for Fly Pages.
   Dark pond at dusk: deep teal, warm sunset accents, one duck-yellow highlight. */
:root {
  --bg: #0a1417;
  --bg2: #0e1c21;
  --panel: #10242b;
  --panel2: #143038;
  --line: #1e3d47;
  --ink: #e8f4f2;
  --muted: #86a6a6;
  --duck: #ffd54a;
  --duck-deep: #f4a742;
  --pond: #3fd0c9;
  --pond-deep: #1b9c9c;
  --pink: #ff7a9c;
  --radius: 14px;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(63,208,201,.10), transparent 60%),
    radial-gradient(900px 500px at 0% 10%, rgba(255,122,156,.08), transparent 55%),
    var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--pond); text-decoration: none; }
a:hover { color: var(--duck); }
.wrap { max-width: 940px; margin: 0 auto; padding: 0 22px; }

/* header */
header {
  position: sticky; top: 0; z-index: 10;
  backdrop-filter: blur(10px);
  background: rgba(10,20,23,.72);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; gap: 18px; height: 62px; }
.brand { font-weight: 800; font-size: 1.05rem; letter-spacing: -.02em; margin-right: auto; color: var(--ink); }
.brand span { color: var(--duck); }
.nav a.link { color: var(--muted); font-size: .93rem; font-weight: 600; }
.nav a.link:hover { color: var(--ink); }

/* hero */
.hero { padding: 74px 0 34px; }
.eyebrow {
  display: inline-block; font-family: var(--mono); font-size: .74rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--pond); border: 1px solid var(--line);
  padding: 5px 11px; border-radius: 999px; margin-bottom: 22px; background: var(--panel);
}
h1 {
  font-size: clamp(2.3rem, 6vw, 3.7rem); line-height: 1.03; letter-spacing: -.03em;
  margin: 0 0 18px; font-weight: 850;
}
h1 .grad {
  background: linear-gradient(105deg, var(--duck), var(--pink) 55%, var(--pond));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lede { font-size: 1.22rem; color: #bcd6d3; max-width: 620px; margin: 0 0 30px; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

/* buttons */
.btn {
  font: inherit; font-weight: 700; cursor: pointer; border: none; border-radius: 11px;
  padding: 13px 22px; font-size: 1rem; transition: transform .08s ease, filter .15s ease;
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn-duck { background: linear-gradient(180deg, var(--duck), var(--duck-deep)); color: #3a2600; box-shadow: 0 6px 22px rgba(255,167,66,.28); }
.btn-duck:hover { filter: brightness(1.06); }
.btn-ghost { background: var(--panel2); color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--pond); }
.btn:disabled { opacity: .55; cursor: wait; }

/* panels */
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
section { padding: 30px 0; }
.section-title { font-size: 1.5rem; letter-spacing: -.02em; margin: 0 0 6px; }
.section-sub { color: var(--muted); margin: 0 0 20px; }

/* the summon stage */
.stage { padding: 26px; margin-top: 18px; text-align: center; }
.duck-art {
  font-family: var(--mono); white-space: pre; color: var(--duck);
  font-size: 1.05rem; line-height: 1.25; margin: 4px 0 16px; min-height: 5em;
  display: flex; align-items: center; justify-content: center;
}
.tip { font-size: 1.16rem; max-width: 560px; margin: 0 auto 12px; min-height: 2.4em; }
.tip-meta { font-family: var(--mono); font-size: .78rem; color: var(--muted); }
.tag { display:inline-block; font-family: var(--mono); font-size: .68rem; padding: 2px 7px; border-radius: 6px; border:1px solid var(--line); color: var(--pond); }

/* stats strip */
.stats { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 20px; }
.stat { flex: 1; min-width: 150px; padding: 16px 18px; }
.stat .num { font-size: 1.9rem; font-weight: 800; color: var(--duck); font-variant-numeric: tabular-nums; }
.stat .lbl { font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }

/* the pond */
.pond-form { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.pond-form input, .pond-form textarea {
  font: inherit; background: var(--bg2); border: 1px solid var(--line); color: var(--ink);
  border-radius: 10px; padding: 11px 13px;
}
.pond-form input { flex: 0 0 190px; }
.pond-form textarea { flex: 1; min-width: 220px; resize: vertical; min-height: 44px; }
.pond-form input:focus, .pond-form textarea:focus { outline: none; border-color: var(--pond); }
.notes { display: grid; gap: 10px; }
.note { padding: 14px 16px; }
.note .who { font-weight: 700; color: var(--pond); }
.note .when { font-family: var(--mono); font-size: .72rem; color: var(--muted); float: right; }
.note .body { margin-top: 4px; color: #d7ebe8; }

/* agent box */
.agent { border: 1px dashed var(--pond-deep); background: linear-gradient(180deg, rgba(63,208,201,.05), transparent); padding: 24px; }
pre.code {
  font-family: var(--mono); background: #071013; border: 1px solid var(--line);
  border-radius: 10px; padding: 14px 16px; overflow-x: auto; font-size: .86rem; color: #cfeae7;
}
pre.code .c { color: var(--muted); }
.md-out { margin-top: 14px; max-height: 260px; overflow: auto; white-space: pre-wrap; }

/* features */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.feat { padding: 18px 20px; }
.feat h3 { margin: 0 0 6px; font-size: 1.02rem; }
.feat h3 .i { margin-right: 8px; }
.feat p { margin: 0; color: var(--muted); font-size: .92rem; }

/* article (docs/about) */
.article { padding: 20px 0 40px; }
.article h1 { font-size: 2.2rem; margin-bottom: 8px; }
.article h2 { margin-top: 34px; font-size: 1.35rem; letter-spacing: -.01em; }
.article h3 { margin-top: 22px; font-size: 1.05rem; }
.article code { font-family: var(--mono); background: var(--panel2); padding: 1px 6px; border-radius: 5px; font-size: .88em; }
.article pre code { display: block; padding: 14px 16px; background: #071013; border: 1px solid var(--line); border-radius: 10px; overflow-x: auto; }
.article table { border-collapse: collapse; width: 100%; margin: 14px 0; }
.article th, .article td { border: 1px solid var(--line); padding: 8px 12px; text-align: left; font-size: .92rem; }
.article th { background: var(--panel2); }

/* footer */
footer { border-top: 1px solid var(--line); margin-top: 30px; padding: 30px 0 50px; color: var(--muted); font-size: .9rem; }
footer .wrap { display: flex; gap: 10px 24px; flex-wrap: wrap; align-items: center; }
footer a { margin-right: 16px; }
.flag { margin-left: auto; font-family: var(--mono); font-size: .78rem; }

/* 404 */
.center-screen { min-height: 70vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.big404 { font-family: var(--mono); font-size: 4rem; color: var(--duck); white-space: pre; line-height: 1.15; }

.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--panel2); border: 1px solid var(--pond); color: var(--ink); padding: 11px 18px; border-radius: 10px; opacity: 0; transition: opacity .2s; pointer-events: none; }
.toast.show { opacity: 1; }
