/* ============================================
   PAFIRA.AI — DESIGN SYSTEM & STYLES
   ============================================ */

/* ---- CSS Custom Properties ---- */
:root {
  --dark-teal: #143740;
  --light-teal: #d1eae7;
  --teal-mid: #1a4a55;
  --orange: #c97b4b;
  --orange-light: #e0a87e;
  --body-text: #333333;
  --text-light: #6b7b80;
  --white: #ffffff;
  --off-white: #f7faf9;
  --light-bg: #f5f5f5;
  --card-radius: 40px;
  --btn-radius: 50px;
  --section-padding: 120px 0;
  --container-width: 1200px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---- Reset ---- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    sans-serif;
  font-weight: 400;
  color: var(--body-text);
  line-height: 1.7;
  background: var(--white);
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5 {
  font-family: "IBM Plex Serif", Georgia, "Times New Roman", serif;
  font-weight: 500;
  line-height: 1.2;
  color: var(--dark-teal);
}

h1 {
  font-size: clamp(2.8rem, 5vw, 4.2rem);
}
h2 {
  font-size: clamp(2rem, 3.5vw, 2.8rem);
}
h3 {
  font-size: clamp(1.2rem, 2vw, 1.5rem);
}

/* ---- Utilities ---- */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

.label {
  display: inline-block;
  font-family: "Inter", sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 16px;
}

.label--light {
  color: var(--light-teal);
}

.text-white {
  color: var(--white);
}
.text-light {
  color: rgba(255, 255, 255, 0.8);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 36px;
  border-radius: var(--btn-radius);
  font-family: "Inter", sans-serif;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn--primary {
  background: var(--light-teal);
  color: var(--dark-teal);
}
.btn--primary:hover {
  background: #b8ddd8;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(20, 55, 64, 0.15);
}

.btn--secondary {
  background: transparent;
  color: var(--dark-teal);
  border: 2px solid var(--dark-teal);
}
.btn--secondary:hover {
  background: var(--dark-teal);
  color: var(--white);
}

.btn--accent {
  background: var(--orange);
  color: var(--white);
}
.btn--accent:hover {
  background: #b5693f;
  transform: translateY(-2px);
}

.btn--nav {
  padding: 10px 28px;
  background: var(--light-teal);
  color: var(--dark-teal);
  font-size: 0.88rem;
}

/* Arch mask for images */
.arch-mask {
  border-radius: 200px 200px 40px 40px;
  overflow: hidden;
  width: 380px;
  height: 480px;
}
.arch-mask img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.arch-mask--large {
  width: 460px;
  height: 560px;
}
.arch-mask--sm {
  width: 200px;
  height: 250px;
  border-radius: 120px 120px 24px 24px;
}

/* ---- Animations ---- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.anim-fade {
  opacity: 0;
  transform: translateY(40px);
  transition:
    opacity 0.8s ease,
    transform 0.8s ease;
}

.anim-fade.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 20px 0;
  transition: all var(--transition);
}

.nav--scrolled {
  background: rgba(20, 55, 64, 0.95);
  backdrop-filter: blur(20px);
  padding: 12px 0;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.nav__inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  color: var(--white);
  font-family: "IBM Plex Serif", serif;
  font-weight: 600;
  font-size: 1.6rem;
}

.nav__logo-icon {
  height: 28px;
  width: auto;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav__links a {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.9rem;
  font-weight: 400;
  transition: color var(--transition);
  position: relative;
}

.nav__links a:hover {
  color: var(--white);
}

.nav__links a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--light-teal);
  transition: width var(--transition);
}

.nav__links a:hover::after {
  width: 100%;
}

.nav__link--highlight {
  color: var(--light-teal) !important;
  font-weight: 500 !important;
}

.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav__hamburger span {
  width: 24px;
  height: 2px;
  background: var(--white);
  transition: all var(--transition);
  border-radius: 2px;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dark-teal);
  background-image: url("images/hero-bg-real.png");
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(20, 55, 64, 0.92) 0%,
    rgba(20, 55, 64, 0.75) 50%,
    rgba(20, 55, 64, 0.85) 100%
  );
}

.hero__content {
  position: relative;
  text-align: center;
  max-width: 720px;
  padding: 0 24px;
}

.hero__content--left {
  text-align: left;
  max-width: 1200px;
  width: 100%;
  padding: 0 80px;
}

.hero__title {
  color: var(--white);
  margin-bottom: 24px;
  letter-spacing: -1px;
}

.hero__subtitle {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.15rem;
  line-height: 1.8;
  margin-bottom: 40px;
  max-width: 560px;
}

.hero__content--left .hero__subtitle {
  margin-left: 0;
  margin-right: auto;
}

/* ============================================
   PROBLEM
   ============================================ */
.problem {
  padding: var(--section-padding);
  background: var(--white);
}

.problem__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.problem__text h2 {
  margin-bottom: 24px;
}

.problem__text p {
  margin-bottom: 16px;
  font-size: 1.05rem;
  color: var(--text-light);
}

.problem__image {
  display: flex;
  justify-content: center;
}

/* ============================================
   QUOTE
   ============================================ */
.quote-section {
  padding: 80px 0;
  background: var(--off-white);
}

.quote__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.quote__text {
  text-align: left;
}

.quote__block {
  max-width: 800px;
  text-align: left;
}

.quote__block p {
  font-family: "IBM Plex Serif", serif;
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  font-weight: 400;
  font-style: italic;
  color: var(--dark-teal);
  line-height: 1.6;
  margin-bottom: 32px;
}

.quote__block cite {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-style: normal;
}

.quote__block cite strong {
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  color: var(--dark-teal);
}

.quote__block cite span {
  font-size: 0.88rem;
  color: var(--text-light);
}

.quote__image {
  display: flex;
  justify-content: center;
}

/* ============================================
   PATIENT APP
   ============================================ */
.app-section {
  padding: var(--section-padding);
  background: var(--dark-teal);
}

.app-section__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.app-section__text h2 {
  color: var(--white);
  margin-bottom: 24px;
}

.app-section__text p {
  margin-bottom: 32px;
}

.app-section__features {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.app-feature {
  display: flex;
  align-items: center;
  gap: 16px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
}

.app-feature__line {
  width: 40px;
  height: 2px;
  background: var(--light-teal);
  flex-shrink: 0;
}

.app-section__phone {
  display: flex;
  justify-content: center;
}

.app-phone-container {
  position: relative;
  display: inline-block;
}

.app-phone-container img {
  max-width: 360px;
  border-radius: 32px;
  filter: drop-shadow(0 20px 60px rgba(0, 0, 0, 0.3));
}

/* App Annotation Labels */
.app-annotation {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.app-annotation__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--orange);
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(201, 123, 75, 0.3);
}

.app-annotation__label {
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(20, 55, 64, 0.6);
  backdrop-filter: blur(8px);
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid rgba(209, 234, 231, 0.2);
}

.app-annotation--top-left {
  top: 8%;
  right: 105%;
  flex-direction: row-reverse;
}

.app-annotation--top-right {
  top: 18%;
  left: 105%;
}

.app-annotation--mid-left {
  top: 42%;
  right: 105%;
  flex-direction: row-reverse;
}

.app-annotation--mid-right {
  top: 58%;
  left: 105%;
}

.app-annotation--bottom {
  bottom: 12%;
  left: 50%;
  transform: translateX(-50%);
  flex-direction: column;
}

/* ============================================
   APPROACH
   ============================================ */
.approach {
  padding: var(--section-padding);
  background: var(--white);
}

.approach__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.approach__image {
  display: flex;
  justify-content: center;
}

.approach__text h2 {
  margin-bottom: 24px;
}

.approach__text p {
  margin-bottom: 16px;
  font-size: 1.05rem;
  color: var(--text-light);
}

/* ============================================
   HOW IT WORKS
   ============================================ */
.how-it-works {
  padding: var(--section-padding);
  background: var(--off-white);
}

.how-it-works__header {
  text-align: center;
  margin-bottom: 64px;
}

.how-it-works__header h2 {
  max-width: 500px;
  margin: 0 auto;
}

.how-it-works__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

.hiw-card {
  background: var(--white);
  padding: 40px 28px;
  border-radius: var(--card-radius);
  text-align: center;
  transition: all var(--transition);
  box-shadow: 0 2px 20px rgba(20, 55, 64, 0.04);
}

.hiw-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 48px rgba(20, 55, 64, 0.1);
}

.hiw-card__icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 24px;
}

.hiw-card h3 {
  margin-bottom: 12px;
  font-size: 1.15rem;
}

.hiw-card p {
  font-size: 0.92rem;
  color: var(--text-light);
  line-height: 1.6;
}

/* ============================================
   STAKEHOLDER CARDS
   ============================================ */
.stakeholders {
  padding: var(--section-padding);
  background: var(--white);
}

.stakeholders__header {
  text-align: center;
  margin-bottom: 64px;
}

.stakeholders__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.stake-card {
  background: var(--off-white);
  padding: 40px;
  border-radius: var(--card-radius);
  transition: all var(--transition);
}

.stake-card:hover {
  box-shadow: 0 16px 48px rgba(20, 55, 64, 0.08);
  transform: translateY(-4px);
}

.stake-card__icon {
  width: 40px;
  height: 40px;
  margin-bottom: 20px;
}

.stake-card h3 {
  margin-bottom: 20px;
}

.stake-card__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.stake-card__list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.95rem;
  color: var(--text-light);
}

.check {
  color: var(--dark-teal);
  font-weight: 600;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--light-teal);
  border-radius: 50%;
  font-size: 0.7rem;
}

/* ============================================
   COMPLIANCE
   ============================================ */
.compliance {
  padding: var(--section-padding);
  background: var(--dark-teal);
}

.compliance__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.compliance__text h2 {
  color: var(--white);
  margin-bottom: 24px;
}

.compliance__text p {
  margin-bottom: 32px;
}

.compliance__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.compliance-badge {
  padding: 8px 20px;
  border: 1px solid rgba(209, 234, 231, 0.3);
  border-radius: var(--btn-radius);
  color: var(--light-teal);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* Compliance Image */
.compliance__image {
  width: 100%;
  max-width: 600px;
  border-radius: 16px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.15);
}

/* ============================================
   FAQ
   ============================================ */
.faq {
  padding: var(--section-padding);
  background: var(--white);
}

.faq__header {
  text-align: center;
  margin-bottom: 64px;
}

.faq__list {
  max-width: 780px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid rgba(20, 55, 64, 0.1);
}

.faq-item__question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 24px 0;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: "IBM Plex Serif", serif;
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--dark-teal);
  transition: color var(--transition);
  gap: 16px;
}

.faq-item__question:hover {
  color: var(--orange);
}

.faq-item__toggle {
  font-family: "Inter", sans-serif;
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--dark-teal);
  transition: all var(--transition);
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.faq-item.active .faq-item__toggle {
  transform: rotate(45deg);
  color: var(--orange);
}

.faq-item.active .faq-item__question {
  color: var(--orange);
}

.faq-item__answer {
  max-height: 0;
  overflow: hidden;
  transition:
    max-height 0.4s ease,
    padding 0.4s ease;
}

.faq-item.active .faq-item__answer {
  max-height: 300px;
  padding-bottom: 24px;
}

.faq-item__answer p {
  font-size: 0.98rem;
  color: var(--text-light);
  line-height: 1.7;
}

/* ============================================
   CLINICAL TRIALS SEARCH
   ============================================ */
.trials-search {
  padding: var(--section-padding);
  background: var(--off-white);
}

.trials-search__header {
  text-align: center;
  margin-bottom: 48px;
}

.trials-search__header p {
  max-width: 600px;
  margin: 16px auto 0;
  color: var(--text-light);
  font-size: 1.05rem;
}

/* Search Bar */
.search-bar {
  display: flex;
  gap: 12px;
  max-width: 800px;
  margin: 0 auto 20px;
  background: var(--white);
  border-radius: var(--btn-radius);
  padding: 8px 8px 8px 24px;
  box-shadow: 0 4px 24px rgba(20, 55, 64, 0.08);
  border: 2px solid transparent;
  transition: border-color var(--transition);
}

.search-bar:focus-within {
  border-color: var(--light-teal);
}

.search-bar__input-group {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-bar__icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  opacity: 0.5;
}

.search-bar__input {
  flex: 1;
  border: none;
  outline: none;
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  color: var(--dark-teal);
  background: transparent;
}

.search-bar__input::placeholder {
  color: #a0b3b8;
}

.btn--search {
  flex-shrink: 0;
}

/* Filters */
.search-filters {
  display: flex;
  gap: 12px;
  max-width: 800px;
  margin: 0 auto;
  justify-content: center;
  flex-wrap: wrap;
}

.search-filter {
  padding: 10px 20px;
  border: 2px solid rgba(20, 55, 64, 0.12);
  border-radius: var(--btn-radius);
  font-family: "Inter", sans-serif;
  font-size: 0.88rem;
  color: var(--dark-teal);
  background: var(--white);
  cursor: pointer;
  outline: none;
  transition: border-color var(--transition);
  -webkit-appearance: none;
  appearance: none;
}

select.search-filter {
  padding-right: 32px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23143740' width='16' height='16'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

.search-filter:focus {
  border-color: var(--light-teal);
}

.search-filter--text {
  min-width: 200px;
}

/* Results */
.trials-results {
  margin-top: 48px;
}

.trials-results__summary {
  text-align: center;
  margin-bottom: 32px;
  font-size: 0.95rem;
  color: var(--text-light);
}

.trials-results__summary span {
  font-weight: 600;
  color: var(--dark-teal);
}

.trials-results__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 24px;
}

/* Trial Card */
.trial-card {
  background: var(--white);
  border-radius: 24px;
  padding: 32px;
  box-shadow: 0 2px 16px rgba(20, 55, 64, 0.05);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  gap: 16px;
  border: 1px solid rgba(20, 55, 64, 0.06);
}

.trial-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(20, 55, 64, 0.1);
}

.trial-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.trial-card__nct {
  font-family: "Inter", sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-light);
  letter-spacing: 0.5px;
}

.trial-card__status {
  display: inline-flex;
  padding: 4px 12px;
  border-radius: var(--btn-radius);
  font-family: "Inter", sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.trial-card__status--recruiting {
  background: #e3f5e0;
  color: #2d7d2f;
}
.trial-card__status--completed {
  background: #e0ecf5;
  color: #2d5a7d;
}
.trial-card__status--active {
  background: #fef3e0;
  color: #8b6914;
}
.trial-card__status--default {
  background: #f0f0f0;
  color: #666;
}

.trial-card__title {
  font-family: "IBM Plex Serif", serif;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--dark-teal);
  line-height: 1.4;
}

.trial-card__desc {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.trial-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.trial-card__tag {
  padding: 4px 12px;
  background: var(--light-teal);
  color: var(--dark-teal);
  border-radius: var(--btn-radius);
  font-size: 0.75rem;
  font-weight: 500;
}

.trial-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid rgba(20, 55, 64, 0.06);
}

.trial-card__meta {
  font-size: 0.82rem;
  color: var(--text-light);
}

.trial-card__link {
  font-family: "Inter", sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--dark-teal);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color var(--transition);
}

.trial-card__link:hover {
  color: var(--orange);
}

.trial-card__link svg {
  width: 16px;
  height: 16px;
}

/* Loading */
.trials-results__loading {
  text-align: center;
  padding: 64px 0;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--light-teal);
  border-top-color: var(--dark-teal);
  border-radius: 50%;
  margin: 0 auto 16px;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.trials-results__loading p {
  color: var(--text-light);
  font-size: 0.95rem;
}

.trials-results__empty,
.trials-results__error {
  text-align: center;
  padding: 64px 0;
}

.trials-results__empty p,
.trials-results__error p {
  color: var(--text-light);
  margin-top: 16px;
}

.trials-results__error p {
  color: var(--orange);
}

#load-more {
  display: block;
  margin: 40px auto 0;
}

/* ============================================
   INVESTORS
   ============================================ */
.investors {
  padding: var(--section-padding);
  background: var(--dark-teal);
}

.investors__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.investors__text {
  text-align: left;
}

.investors__heading {
  font-family: "IBM Plex Serif", serif;
  color: var(--orange);
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  margin-bottom: 24px;
}

.investors__text p {
  margin-bottom: 20px;
}

.investors__email-group {
  margin-bottom: 24px;
}

.investors__email-input {
  width: 100%;
  max-width: 400px;
  padding: 14px 20px;
  border-radius: var(--btn-radius);
  border: none;
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  background: var(--white);
  color: var(--dark-teal);
}

.investors__email-input::placeholder {
  color: #999;
}

.investors__image {
  display: flex;
  justify-content: center;
}

.investors__brief-img {
  max-width: 340px;
  width: 100%;
  transform: rotate(3deg);
  border-radius: 8px;
  filter: drop-shadow(0 20px 50px rgba(0, 0, 0, 0.3));
  transition: transform var(--transition);
}

.investors__brief-img:hover {
  transform: rotate(0deg) scale(1.02);
}

.btn--outline-light {
  display: inline-block;
  padding: 14px 36px;
  border-radius: var(--btn-radius);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--white);
  border: 2px solid rgba(209, 234, 231, 0.4);
  background: transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn--outline-light:hover {
  border-color: var(--light-teal);
  background: rgba(209, 234, 231, 0.1);
}

/* ============================================
   TEAM
   ============================================ */
.team {
  padding: var(--section-padding);
  background: var(--white);
}

.team__header {
  margin-bottom: 48px;
}

.team__header h2 {
  font-size: 2rem;
  color: var(--dark-teal);
}

.team__grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 24px;
}

.team-card {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  cursor: pointer;
}

.team-card--large {
  grid-row: 1 / 3;
  aspect-ratio: auto;
}

.team-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.team-card__name {
  position: absolute;
  top: 16px;
  left: 16px;
  color: var(--dark-teal);
  font-weight: 600;
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.75);
  padding: 4px 12px;
  border-radius: 6px;
  backdrop-filter: blur(4px);
}

.team-card__overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--dark-teal);
  color: #fff;
  padding: 20px 16px;
  transform: translateY(100%);
  transition: transform 0.35s ease;
}

.team-card__overlay p {
  font-size: 0.85rem;
  line-height: 1.5;
  margin: 0;
}

.team-card:hover .team-card__overlay {
  transform: translateY(0);
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--dark-teal);
  padding: 80px 0 0;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 80px;
  padding-bottom: 60px;
}

/* Contact Form */
.footer__form-title {
  font-family: 'IBM Plex Serif', serif;
  color: var(--orange);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 500;
  margin-bottom: 32px;
}

.contact-form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.contact-form__input,
.contact-form__textarea {
  width: 100%;
  padding: 16px 20px;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  color: var(--white);
  outline: none;
  transition: background var(--transition);
}

.contact-form__input::placeholder,
.contact-form__textarea::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.contact-form__input:focus,
.contact-form__textarea:focus {
  background: rgba(255, 255, 255, 0.12);
}

.contact-form__textarea {
  resize: vertical;
  min-height: 140px;
  margin-bottom: 20px;
}

.btn--send {
  display: inline-block;
  padding: 14px 40px;
  border-radius: var(--btn-radius);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--dark-teal);
  background: var(--light-teal);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
}

.btn--send:hover {
  background: var(--white);
  transform: translateY(-2px);
}

/* Footer Info */
.footer__info {
  padding-top: 16px;
}

.footer__logo-area {
  margin-bottom: 32px;
}

.footer__logo-svg {
  width: 140px;
  color: var(--white);
  margin-bottom: 16px;
}

.footer__info-title {
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 24px;
}

.footer__info-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.footer__info-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

.footer__info-list li svg {
  flex-shrink: 0;
  color: rgba(255, 255, 255, 0.5);
}

.footer__info-list a {
  color: rgba(255, 255, 255, 0.7);
  transition: color var(--transition);
}

.footer__info-list a:hover {
  color: var(--white);
}

.footer__copy-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 24px;
  text-align: center;
}

.footer__copy-bar p {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.35);
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* Prevent horizontal overflow on all devices */
html, body {
  overflow-x: hidden;
}

@media (max-width: 1024px) {
  .how-it-works__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .team__grid {
    grid-template-columns: 1fr 1fr 1fr;
  }
  .footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .investors__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .investors__image {
    display: none;
  }

  .quote__grid {
    gap: 40px;
  }
}

@media (max-width: 768px) {
  :root {
    --section-padding: 60px 0;
  }

  .container {
    padding: 0 20px;
  }

  /* Nav */
  .nav__hamburger {
    display: flex;
  }

  .nav__links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--dark-teal);
    flex-direction: column;
    padding: 24px;
    gap: 20px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.2);
  }

  .nav__links.active {
    display: flex;
  }

  .nav__links a::after {
    display: none;
  }

  /* Hero */
  .hero {
    padding-top: 100px;
    min-height: auto;
  }

  .hero__title {
    font-size: clamp(2rem, 8vw, 3rem);
  }

  .hero__subtitle {
    font-size: 1rem;
  }

  .hero__buttons {
    flex-direction: column;
    gap: 12px;
  }

  .hero__buttons .btn {
    width: 100%;
    text-align: center;
  }

  /* Quote section */
  .quote-section {
    padding: 60px 0;
  }

  .quote__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .quote__image {
    order: -1;
  }

  .arch-mask,
  .arch-mask--large {
    width: 100%;
    max-width: 300px;
    height: auto;
    aspect-ratio: 3 / 4;
    margin: 0 auto;
  }

  .quote__block p {
    font-size: 1.2rem;
  }

  /* Problem section */
  .problem__grid,
  .app-section__grid,
  .approach__grid,
  .compliance__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .approach__image {
    order: -1;
  }

  /* How it works */
  .how-it-works__grid {
    grid-template-columns: 1fr;
  }

  /* Stakeholders */
  .stakeholders__grid {
    grid-template-columns: 1fr;
  }

  /* Changes in practice */
  .changes__grid {
    grid-template-columns: 1fr;
  }

  /* Team */
  .team__grid {
    grid-template-columns: 1fr 1fr;
  }

  .team-card--large {
    grid-column: 1 / -1;
    grid-row: auto;
    aspect-ratio: 4 / 3;
  }

  .team__header h2 {
    font-size: 1.6rem;
  }

  /* Investors */
  .investors__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .investors__image {
    display: none;
  }

  .investors__email-input {
    width: 100%;
    max-width: 100%;
  }

  /* FAQ */
  .faq__grid {
    grid-template-columns: 1fr;
  }

  .faq h2 {
    font-size: 1.5rem;
  }

  /* Better trials CTA */
  .better-trials-cta h2 {
    font-size: clamp(1.5rem, 5vw, 2.2rem);
  }

  .better-trials-cta p {
    font-size: 0.95rem;
  }

  /* Footer */
  .footer__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  /* Search */
  .search-bar {
    flex-direction: column;
    border-radius: 24px;
    padding: 12px;
  }

  .search-bar__input-group {
    padding: 8px 12px;
  }

  .btn--search {
    width: 100%;
  }

  .search-filters {
    flex-direction: column;
  }

  .trials-results__grid {
    grid-template-columns: 1fr;
  }

  /* Contact */
  .contact-form__row {
    grid-template-columns: 1fr;
  }

  /* App annotations */
  .app-annotation {
    display: none;
  }

  /* General text scaling */
  h2 {
    font-size: clamp(1.5rem, 5vw, 2.5rem);
  }

  .section-title {
    font-size: clamp(1.5rem, 5vw, 2.5rem);
  }
}

@media (max-width: 480px) {
  :root {
    --section-padding: 48px 0;
  }

  .container {
    padding: 0 16px;
  }

  /* Hero */
  .hero__title {
    font-size: 1.8rem;
  }

  .hero__subtitle {
    font-size: 0.9rem;
  }

  /* Team - single column on very small */
  .team__grid {
    grid-template-columns: 1fr;
  }

  .team-card--large {
    grid-column: auto;
    aspect-ratio: 1 / 1;
  }

  /* Quote */
  .arch-mask,
  .arch-mask--large {
    width: 100%;
    max-width: 240px;
    height: auto;
    aspect-ratio: 3 / 4;
  }

  .quote__block p {
    font-size: 1.05rem;
  }

  /* Buttons */
  .btn {
    padding: 12px 24px;
    font-size: 0.85rem;
  }

  /* Footer */
  .footer {
    padding: 48px 0 0;
  }

  /* Better trials */
  .better-trials-cta h2 {
    font-size: 1.4rem;
  }

  .better-trials-cta p {
    font-size: 0.88rem;
  }
}
