/* ------------------------------------------------------------
   prose — HSC English tutoring
   Single stylesheet. Plain CSS. No frameworks.
   ------------------------------------------------------------ */

:root {
  --bg: #fdfcf9;
  --ink: #2a2a2a;
  --muted: #6e6e6e;
  --coral: #e0938a;
  --coral-soft: #f6e5e0;
  --rule: #ece6e2;
  --max: 760px;
}

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

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

body {
  margin: 0;
  font-family: 'EB Garamond', Georgia, 'Times New Roman', serif;
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

/* -------- Navigation -------- */

nav.site {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  padding: 1.25rem 0 1.5rem;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 2.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
  color: var(--coral);
}

.brand .logotype { height: 36px; width: 104px; flex: none; }

nav.site ul {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

nav.site a {
  color: var(--ink);
  text-decoration: none;
  font-size: 1rem;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  transition: border-color 120ms ease, color 120ms ease;
}

nav.site a:hover,
nav.site a:focus-visible { color: var(--coral); border-bottom-color: var(--coral); outline: none; }

nav.site a[aria-current="page"] { color: var(--coral); border-bottom-color: var(--coral); }

/* -------- Typography -------- */

h1, h2 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 500;
  color: var(--coral);
  margin: 0 0 1rem;
  letter-spacing: -0.01em;
  line-height: 1.1;
}

h1 { font-size: clamp(2rem, 5vw, 2.75rem); font-style: italic; text-transform: lowercase; }
h2 { font-size: 1.5rem; margin-top: 2.5rem; }
main h2 { border-top: 1px solid var(--rule); padding-top: 2rem; }
.h2-sub { display: block; font-size: 0.9rem; font-weight: 400; margin-top: 0.2em; }

p { margin: 0 0 1.1rem; }

a { color: var(--coral); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

em, i { font-style: italic; }

.tagline { color: var(--muted); margin-top: 0.25rem; margin-bottom: 0.25rem; font-size: 1rem; }
.affiliation {
  color: var(--muted);
  font-size: 0.8rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  margin-top: 0.25rem;
  margin-bottom: 1.75rem;
}

/* Subtle coral marker highlight for a key phrase */
.mark-coral { background: var(--coral-soft); padding: 0.05em 0.25em; border-radius: 2px; }

/* -------- Hero (homepage two-column) -------- */

.hero { display: grid; grid-template-columns: 1.4fr 1fr; gap: 3rem; align-items: start; }

.hero h1 { font-style: italic; font-size: clamp(1.6rem, 4vw, 2.2rem); }

.portrait-wrap {
  justify-self: end;
  align-self: start;
  position: relative;
  padding: 0 0 10px 10px;
}
.portrait-wrap::after {
  content: '';
  position: absolute;
  top: 10px;
  left: 0;
  right: 10px;
  bottom: 0;
  border: 2px solid var(--coral);
  border-radius: 6px;
}
.portrait-wrap img {
  display: block;
  width: 100%;
  max-width: 260px;
  border-radius: 4px;
  position: relative;
  z-index: 1;
}

@media (max-width: 640px) {
  .hero { grid-template-columns: 1fr; gap: 1.5rem; }
  .portrait-wrap { justify-self: start; }
  .portrait-wrap img { max-width: 220px; }
}

/* -------- Inline CTAs (text links, not buttons) -------- */

.cta-row { display: flex; flex-wrap: wrap; gap: 1.5rem; margin-top: 2rem; }
.cta-row a { font-size: 1rem; }

/* -------- Testimonials -------- */

blockquote {
  margin: 0 0 2.25rem;
  padding-left: 1.25rem;
  border-left: 2px solid var(--coral);
  font-style: italic;
  color: #3a3a3a;
}
blockquote p { margin-bottom: 0.5rem; }
blockquote cite {
  font-style: normal;
  display: block;
  color: var(--muted);
  font-size: 0.95rem;
}
blockquote cite .name { color: var(--coral); font-weight: 500; }

/* -------- Carousel -------- */

.carousel {
  position: relative;
  margin: 2rem 0;
}

.carousel-viewport {
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform 360ms ease;
}

.carousel-slide {
  flex: 0 0 100%;
  padding: 0 2.25rem;
}

.carousel-slide blockquote {
  border-left: none;
  padding: 2rem 2rem 1.5rem;
  border: 1px solid var(--rule);
  border-radius: 6px;
  margin: 0;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  background: none;
  border: none;
  padding: 0.25rem 0.4rem;
  color: var(--coral);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.5;
  transition: opacity 120ms ease;
  font-family: inherit;
}
.carousel-arrow:hover { background: none; color: var(--coral); opacity: 1; }
.carousel-arrow:disabled { opacity: 0.15; cursor: default; }
.carousel-arrow.prev { left: 0; }
.carousel-arrow.next { right: 0; }

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 1.5rem;
}

.carousel-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--rule);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 120ms ease;
}
.carousel-dot:hover { background: #c8bfb9; color: initial; }
.carousel-dot.active { background: var(--coral); }

/* -------- Contact form -------- */

form { display: flex; flex-direction: column; gap: 1rem; margin: 1.5rem 0 2rem; max-width: 520px; }

label { display: flex; flex-direction: column; gap: 0.3rem; font-size: 0.95rem; color: #444; }

input, textarea {
  font-family: inherit;
  font-size: 1rem;
  padding: 0.65rem 0.8rem;
  border: 1px solid #d8d2ce;
  border-radius: 4px;
  background: #fff;
  color: var(--ink);
  transition: border-color 120ms ease, box-shadow 120ms ease;
}
textarea { resize: vertical; min-height: 140px; }
input:focus, textarea:focus { outline: none; border-color: var(--coral); box-shadow: 0 0 0 3px var(--coral-soft); }

button {
  align-self: flex-start;
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1rem;
  background: transparent;
  color: var(--coral);
  border: 1px solid var(--coral);
  padding: 0.55rem 1.25rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background 120ms ease, color 120ms ease;
}
button:hover { background: var(--coral); color: #fff; }

.form-success {
  color: var(--ink);
  background: var(--coral-soft);
  padding: 1rem 1.25rem;
  border-radius: 4px;
  margin: 1rem 0;
}

.details { color: var(--muted); font-size: 1rem; margin-top: 2rem; }
.details p { margin-bottom: 0.3rem; }

/* -------- More / experience list -------- */

.exp { margin: 1.5rem 0 2.5rem; }
.exp dt { font-weight: 500; color: var(--ink); margin-top: 1.25rem; }
.exp dd { margin: 0.1rem 0 0; color: var(--muted); font-size: 0.95rem; }
.exp dd.desc { color: var(--ink); font-size: 1rem; margin-top: 0.35rem; }

/* -------- Footer -------- */

footer {
  margin-top: 4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.9rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
}
footer a { color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--coral); }

/* -------- Mobile -------- */

/* Remove 300ms tap delay on touch devices */
a, button { touch-action: manipulation; }

@media (max-width: 600px) {

  .wrap { padding: 1.5rem 1.25rem 3rem; }

  nav.site { gap: 0.75rem; padding: 1rem 0 1.25rem; margin-bottom: 2rem; }
  nav.site ul { gap: 0.5rem 1rem; }
  nav.site a { font-size: 0.9rem; }

  h2 { font-size: 1.3rem; margin-top: 2rem; }
  main h2 { padding-top: 1.5rem; }

  footer { margin-top: 3rem; }

  .carousel-slide { padding: 0 1.5rem; }
  .carousel-slide blockquote { padding: 1.25rem 1.25rem 1rem; }

  /* Proper 44px touch targets for carousel controls */
  .carousel-arrow {
    min-width: 44px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    padding: 0;
  }
  .carousel-dots { gap: 1rem; }
  .carousel-dot { width: 10px; height: 10px; }

  form { max-width: 100%; }
  form button { align-self: stretch; }

}
