/* =========================================================
   04. Homepage
   ========================================================= */

.hero {
  max-width: 820px;
  margin: 0 auto 54px;
  padding: 18px 0 4px;
  text-align: center;
}

.hero h1 {
  max-width: 780px;
  margin: 0 auto;
  font-size: clamp(38px, 5vw, 58px);
  letter-spacing: -0.04em;
}

.hero-intro {
  max-width: 680px;
  margin: 16px auto 0;
  color: var(--muted);
  font-size: 16px;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.search-bar {
  position: relative;
  max-width: 560px;
  margin: 0 auto 24px;
}

.search-bar input {
  width: 100%;
  height: 52px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--paper);
  padding: 0 58px 0 22px;
  color: var(--ink);
  font-size: 14px;
  box-shadow: var(--shadow);
  outline: 0;
}

.search-bar input::placeholder {
  color: var(--muted);
}

.search-icon {
  position: absolute;
  right: 6px;
  top: 50%;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: var(--orange-soft);
  color: var(--orange);
  display: grid;
  place-items: center;
  font-size: 18px;
  transform: translateY(-50%);
  cursor: pointer;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 12px 18px;
  font-size: 14px;
  font-weight: 900;
}

.btn-primary {
  background: var(--orange);
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(255, 118, 44, 0.22);
}

.btn-secondary {
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--border);
}

.content-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  gap: 28px;
  align-items: stretch;
}

.content-layout > .panel,
.content-layout > aside {
  height: 100%;
}

.content-layout > aside {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 18px;
}

.content-layout > aside .panel {
  margin-bottom: 0;
}

.panel {
  background: #fffaf3;
  border: 1px solid #e2d3c1;
  border-radius: 22px;
  padding: 28px;
  box-shadow: 0 8px 20px rgba(62, 41, 20, 0.06);
  margin-bottom: 18px;
}

.panel h2 {
  font-size: 30px;
  margin-bottom: 18px;
}

.activity-list {
  display: grid;
  gap: 12px;
}

.activity-row {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: 14px;
  align-items: center;
  border: 1px solid #e2d3c1;
  border-radius: 14px;
  padding: 16px 18px;
  background: #fffaf3;
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.activity-row:hover,
.activity-row:focus-visible {
  border-color: var(--orange);
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(62, 41, 20, 0.1);
  transform: translateY(-1px);
}

.activity-row:focus-visible {
  outline: 3px solid var(--orange-soft);
  outline-offset: 3px;
}

.activity-row h3 {
  margin-bottom: 2px;
  font-family: Inter, system-ui, sans-serif;
  font-size: 15px;
}

.activity-row p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.label {
  display: inline-flex;
  justify-content: center;
  border-radius: 999px;
  padding: 6px 8px;
  background: var(--orange-soft);
  color: var(--orange);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.arrow {
  color: var(--muted);
  font-weight: 900;
}

.side-card {
  margin-bottom: 18px;
}

.side-card h2 {
  font-size: 25px;
  margin-bottom: 12px;
}

.side-card ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
}

.category-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin: 26px 0 46px;
}

.category-card {
  width: 100%;
  min-height: 154px;
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.category-card h3 {
  font-size: 24px;
  margin-bottom: 8px;
}

.category-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.audience-box {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 42px;
  margin: 46px 0;
  padding: 28px 32px;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 24px;
}

.audience-box h2 {
  font-size: 24px;
}

.support {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 38px;
  background: var(--dark);
  color: #ffffff;
  border-radius: 28px;
}

.support h2 {
  font-size: 30px;
}

.support p {
  margin: 10px 0 0;
  color: #d6cec5;
}

.empty-state {
  margin: 0;
  color: var(--muted);
}


/* =========================================================
   Homepage practice entry
   ========================================================= */

.home-practice-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.75fr);
  gap: 28px;
  align-items: stretch;
  margin-bottom: 28px;
}

.practice-hero {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 26px 28px;
  text-align: left;
  background: #fffaf3;
  border: 1px solid #e2d3c1;
  border-radius: 22px;
  box-shadow: 0 8px 20px rgba(62, 41, 20, 0.06);
}

.practice-hero h1 {
  margin-bottom: 18px;
  font-size: clamp(30px, 4vw, 46px);
  letter-spacing: -0.04em;
}

.practice-hero .search-bar {
  max-width: 460px;
  margin: 0 0 22px;
}

.practice-hero .search-bar input {
  height: 44px;
  padding-left: 18px;
  padding-right: 48px;
  font-size: 13px;
}

.practice-hero .search-icon {
  width: 34px;
  height: 34px;
  right: 5px;
  font-size: 15px;
}

.practice-paths {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.practice-paths a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fffaf5;
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
  text-align: center;
}

.practice-paths a:hover,
.practice-paths a:focus {
  border-color: var(--orange);
  color: var(--orange);
  background: var(--orange-soft);
}

.home-practice-layout .homepage-sidebar,
.home-practice-layout .side-card {
  height: 100%;
}

.home-practice-layout .side-card {
  margin-bottom: 0;
}

.side-card a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--muted);
}

.side-card a::after {
  content: "→";
  color: var(--orange);
  font-weight: 900;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.side-card a:hover,
.side-card a:focus {
  border-color: var(--border);
  background: var(--orange-soft);
  color: var(--orange);
}

.side-card a:hover::after,
.side-card a:focus::after {
  opacity: 1;
  transform: translateX(0);
}

.latest-layout {
  grid-template-columns: 1fr;
}

@media (max-width: 900px) {
  .home-practice-layout {
    grid-template-columns: 1fr;
  }

  .practice-hero {
    padding: 22px;
  }

  .practice-hero .search-bar {
    max-width: none;
  }

  .practice-paths {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 520px) {
  .practice-paths {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .hero {
    margin-bottom: 36px;
    text-align: left;
  }

  .hero h1 {
    font-size: clamp(32px, 10vw, 44px);
    text-align: left;
  }

  .hero-intro {
    margin-left: 0;
    margin-right: 0;
  }

  .hero-actions {
    justify-content: flex-start;
  }

  .search-bar,
  .hero .search-bar {
    max-width: none;
    margin-bottom: 22px;
  }

  .content-layout,
  .audience-box,
  .category-strip {
    grid-template-columns: 1fr;
  }

  .content-layout > aside {
    display: block;
  }

  .panel {
    padding: 22px;
  }

  .activity-row {
    grid-template-columns: 1fr auto;
  }

  .activity-row .label {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .category-card {
    min-height: auto;
  }

  .support {
    flex-direction: column;
    align-items: flex-start;
  }
}
