/* extramediumsoftwareco.com. A theme is colours and fonts in custom properties on the body class -
   em for the site, vpp for VideoPhonePeer's page; everything below the themes reads only those. */

:root {
  --gutter: 20px;
  --width: 1080px;
  --radius: 14px;
}

body.em {
  --bg: #f7f7fb;
  --surface: #ffffff;
  --ink: #16161d;
  --muted: #5b5d6b;
  --line: #e4e4ee;
  --accent: #4f46e5;
  --accent-soft: #eef0ff;
  --accent-deep: #4338ca;
  --accent-ink: #ffffff;
  --head: #ffffff;
  --head-ink: #16161d;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Zilla Slab", Georgia, serif;
}

/* VideoPhonePeer's page: the app's own dark and violet, and the logo's rounded Fredoka. */
body.vpp {
  --bg: #14161b;
  --surface: #1c1f26;
  --ink: #e9ecf3;
  --muted: #a7aec0;
  --line: #333947;
  --accent: #ee82ee;
  --accent-ink: #1a1206;
  --head: #0e1014;
  --head-ink: #e9ecf3;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Fredoka", "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main { flex: 1; }

img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); }
body.em main a { color: var(--accent-deep); }

h1, h2, h3 {
  font-family: var(--display);
  line-height: 1.2;
  margin: 0 0 .5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

.wrap {
  max-width: var(--width);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Read out by screen readers and search engines, but not shown. */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: var(--gutter);
  top: 8px;
  z-index: 10;
  background: var(--surface);
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 8px;
}

/* ---------------------------------------------------------------- header */

.site-head {
  background: var(--head);
  color: var(--head-ink);
}
.site-head .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  flex-wrap: wrap;
  padding-top: 12px;
  padding-bottom: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
}
.brand img { height: 40px; width: auto; }
body.em .brand img, body.vpp .brand img { background: #fff; border-radius: 8px; padding: 2px; }

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 6px;
}
.site-nav a {
  display: block;
  color: inherit;
  text-decoration: none;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: .95rem;
  opacity: .85;
}
.site-nav a:hover { opacity: 1; background: rgba(255,255,255,.1); }
.site-nav a[aria-current="page"] {
  opacity: 1;
  background: var(--accent);
  color: var(--accent-ink);
}

/* ---------------------------------------------------------------- buttons */

.btn {
  display: inline-block;
  padding: 11px 24px;
  border-radius: 999px;
  border: 2px solid var(--accent);
  background: var(--accent);
  color: var(--accent-ink) !important;
  font: 600 1rem var(--font);
  text-decoration: none;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, filter .15s;
}
.btn:hover { filter: brightness(1.08); }
.btn.ghost {
  background: transparent;
  color: var(--ink) !important;
  border-color: var(--line);
}
.hero .btn.ghost { color: inherit !important; border-color: currentColor; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.btn-row.center { justify-content: center; }

/* ---------------------------------------------------------------- sections */

.section { padding: 64px 0; }
.section.tight { padding: 40px 0; }
.section.alt { background: var(--surface); }
.center { text-align: center; }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 44em; }
.center .lead { margin-left: auto; margin-right: auto; }
.muted { color: var(--muted); }
.narrow { max-width: 760px; }

.hero {
  padding: 80px 0;
  text-align: center;
}
.hero .lead { color: inherit; opacity: .85; margin-left: auto; margin-right: auto; }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}
.split + .split { margin-top: 56px; }
.split.flip > :first-child { order: 2; }
.split img { border-radius: var(--radius); }
/* A portrait cover (BandPeer's): narrower than its column, so it stands no taller than the text. */
.split img.poster { max-width: 340px; margin: 0 auto; border: 1px solid var(--line); }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.section.alt .card { background: var(--bg); }
.card > img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.card .body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.card .body p { color: var(--muted); }
.card .btn-row { margin-top: auto; padding-top: 8px; }

.tag {
  display: inline-block;
  font-size: .8rem;
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  margin: 0 6px 8px 0;
}
.tag.soft { background: var(--line); color: var(--ink); }

/* Questions and answers */
.faq { max-width: 820px; margin: 0 auto; }
.faq details {
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
}
.faq summary {
  cursor: pointer;
  font-weight: 700;
  font-size: 1.05rem;
}
.faq details p { margin: 10px 0 0; color: var(--muted); }

/* Long text: terms, policies */
.prose { max-width: 760px; margin: 0 auto; }
.prose h2 { font-size: 1.35rem; margin-top: 1.8em; }

/* ---------------------------------------------------------------- forms */

.form { max-width: 620px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; }
.field .opt { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
}
.field textarea { min-height: 170px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.status {
  display: none;
  padding: 14px 18px;
  border-radius: 10px;
  margin-bottom: 22px;
}
.status.ok { background: #e3f4e6; color: #17461f; }
.status.err { background: #fbe4df; color: #6b1c0b; }

/* ---------------------------------------------------------------- footer */

.site-foot {
  background: var(--head);
  color: var(--head-ink);
  padding: 32px 0;
  font-size: .92rem;
}
.site-foot .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px 32px;
}
.site-foot a { color: inherit; opacity: .8; }
.site-foot a:hover { opacity: 1; }
.site-foot ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 20px; }

/* ---------------------------------------------------------------- Extra Medium */

/* A light header that stays put, with a soft pill for the page you're on. */
body.em .site-head {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
body.em .site-nav a:hover { background: var(--accent-soft); }
body.em .site-nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent-deep); font-weight: 600; }

/* The footer stays dark, to close the page. */
body.em .site-foot { background: #16161d; color: #e8e8f0; }

body.em .btn { box-shadow: 0 8px 20px -10px rgba(79, 70, 229, .7); }
body.em .btn:hover { transform: translateY(-1px); box-shadow: 0 12px 24px -10px rgba(79, 70, 229, .8); filter: none; background: var(--accent-deep); border-color: var(--accent-deep); }
body.em .btn.ghost { background: var(--surface); box-shadow: none; }
body.em .btn.ghost:hover { background: var(--surface); border-color: var(--accent); color: var(--accent-deep) !important; }
body.em .hero .btn.ghost { color: var(--ink) !important; border-color: var(--line); }

/* The home hero: a faint indigo glow over a dot grid. */
body.em .hero {
  background:
    radial-gradient(ellipse 60% 70% at 50% 0%, rgba(79, 70, 229, .13), transparent 70%),
    radial-gradient(rgba(22, 22, 29, .07) 1px, transparent 1.5px) 0 0 / 22px 22px,
    var(--surface);
  border-bottom: 1px solid var(--line);
}
body.em .hero img.logo { width: 200px; margin: 0 auto 24px; }

/* Every other page opens on a soft wash of the same indigo. */
body.em main > .section:first-child {
  background: linear-gradient(180deg, var(--accent-soft), rgba(238, 240, 255, 0) 380px);
}

.section-head { text-align: center; margin-bottom: 36px; }
.section-head .lead { margin: 0 auto; }

body.em .card { box-shadow: 0 1px 2px rgba(22, 22, 29, .04); transition: transform .2s, box-shadow .2s; }
body.em .card:hover { transform: translateY(-4px); box-shadow: 0 22px 44px -22px rgba(22, 22, 29, .28); }
body.em .card > img { border-bottom: 1px solid var(--line); }

/* The contact form sits on its own card. */
body.em .form {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: 0 22px 44px -30px rgba(22, 22, 29, .3);
}
body.em .field input, body.em .field select, body.em .field textarea { background: var(--bg); }

/* ---------------------------------------------------------------- VideoPhonePeer */

body.vpp .brand { font-family: "Zilla Slab", Georgia, serif; } /* the header is still the company's */
body.vpp .hero { padding-top: 24px; }
/* The logo is drawn 4:3 for the product cards; here its empty top and bottom are trimmed away. */
body.vpp .hero img.logo { width: min(560px, 100%); aspect-ratio: 1200 / 600; object-fit: cover; margin: 0 auto 24px; }
body.vpp h2, body.vpp h3 { font-weight: 700; }
body.vpp .split img { border: 1px solid var(--line); box-shadow: 0 24px 60px -30px rgba(238, 130, 238, .45); }
body.vpp .card { border-color: var(--line); }

/* A small announcement above the logo. */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 16px 5px 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink) !important;
  text-decoration: none;
  font-size: .92rem;
  margin: 8px 0 16px;
}
.pill b { background: var(--accent); color: var(--accent-ink); border-radius: 999px; padding: 3px 10px; font-size: .8rem; }
.pill:hover { border-color: var(--accent); }

/* The Android app, drawn as a phone with places to call - an illustration, not its real screen. */
.phone-mock {
  width: min(290px, 80vw);
  aspect-ratio: 9 / 16;
  margin: 0 auto;
  border: 10px solid #2a2e38;
  border-radius: 40px;
  background: #0b0c10;
  box-shadow: 0 30px 80px -30px rgba(238, 130, 238, .6);
  position: relative;
}
.phone-mock::before {
  content: "";
  position: absolute;
  top: 10px;
  left: 50%;
  width: 70px;
  height: 18px;
  margin-left: -35px;
  border-radius: 999px;
  background: #2a2e38;
}
.phone-mock .screen {
  height: 100%;
  border-radius: 30px;
  background: radial-gradient(circle at 50% 0%, rgba(238, 130, 238, .16), transparent 55%), #14161b;
  padding: 44px 12px 20px;
}
.phone-mock .app { display: flex; align-items: center; gap: 6px; font: 700 .95rem var(--display); color: var(--muted); }
.phone-mock .app .glyph { color: var(--accent); font: 1.1rem/1 "Segoe UI Symbol", sans-serif; }
.phone-mock .heading { font: 700 1.45rem var(--display); margin: 14px 0 12px; }
.phone-mock .places { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.phone-mock .places li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}
.phone-mock .initial {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(238, 130, 238, .16);
  color: var(--accent);
  font: 700 .95rem var(--display);
}
.phone-mock .place { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; font-size: .92rem; }
.phone-mock .call {
  flex: none;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: .8rem;
}

.specs { list-style: none; margin: 0 auto; padding: 0; max-width: 620px; text-align: left; }
.specs li { padding: 12px 0; border-bottom: 1px solid var(--line); display: flex; gap: 16px; }
.specs b { flex: 0 0 150px; }
.specs span { color: var(--muted); }

/* ---------------------------------------------------------------- coming soon */

.soon { padding: 90px 0; text-align: center; }
.soon .tag { font-size: .9rem; padding: 4px 14px; }

/* ---------------------------------------------------------------- phones */

@media (max-width: 760px) {
  body { font-size: 16px; }
  .section { padding: 44px 0; }
  .hero { padding: 56px 0; }
  .split { grid-template-columns: 1fr; gap: 20px; }
  .split.flip > :first-child { order: 0; }
  .site-head .wrap { justify-content: center; }
  .site-nav ul { justify-content: center; }
  .specs li { flex-direction: column; gap: 2px; }
  .specs b { flex: none; }
  body.em .form { padding: 20px; }
}
