/* ============================================================
   COMPONENTS — buttons, inputs, cards, badges
   ============================================================ */

/* —— Buttons —————————————————————————————————————————— */
.nwl-btn {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 18px;
  height: var(--control-h); padding: 0 28px;
  font-family: var(--font-display); font-weight: 700; font-size: 15px; letter-spacing: -0.005em;
  line-height: 1; border: 2px solid transparent; border-radius: var(--radius-none);
  cursor: pointer; white-space: nowrap; text-decoration: none;
  background: var(--accent); color: var(--accent-contrast);
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.nwl-btn:hover { background: var(--accent-hover); text-decoration: none; color: var(--accent-contrast); }
.nwl-btn svg { flex: none; transition: transform var(--dur-fast) var(--ease-out); }
.nwl-btn:hover svg { transform: translate(2px,-2px); }

.nwl-btn--lg { height: 60px; padding: 0 34px; font-size: 16px; }
.nwl-btn--sm { height: var(--control-h-sm); padding: 0 20px; font-size: 14px; }

.nwl-btn--dark { background: var(--surface-dark); color: #fff; }
.nwl-btn--dark:hover { background: #000; color: #fff; }

.nwl-btn--ghost { background: transparent; color: var(--text-heading); border-color: var(--text-heading); }
.nwl-btn--ghost:hover { background: var(--text-heading); color: #fff; }

.nwl-btn--light { background: #fff; color: var(--text-heading); border-color: var(--border-strong); }
.nwl-btn--light:hover { background: var(--surface-muted); }

.nwl-btn--full { width: 100%; justify-content: center; }
.nwl-btn[disabled] { opacity: 0.45; cursor: not-allowed; }

.nwl-icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; flex: none;
  border: 1px solid rgba(255,255,255,0.22); border-radius: var(--radius-pill);
  background: transparent; color: rgba(255,255,255,0.74);
  cursor: pointer; transition: all var(--dur-fast) var(--ease-out); text-decoration: none;
}
.nwl-icon-btn:hover { background: var(--accent); color: var(--accent-contrast); border-color: var(--accent); }

/* —— Inputs / Textarea —————————————————————————————————— */
.nwl-field { display: block; margin: 0; }
.nwl-field + .nwl-field { margin-top: 18px; }
.nwl-field__label {
  display: block; margin-bottom: 8px;
  font-family: var(--font-body); font-size: 15px; font-weight: 600; color: var(--text-body);
}
.nwl-field--dark .nwl-field__label { color: #fff; }
.nwl-field__control,
.nwl-field select {
  width: 100%; height: var(--control-h); padding: 0 16px;
  font-family: var(--font-body); font-size: 16px; color: var(--text-body);
  background: #fff; border: 1px solid var(--border-strong); border-radius: var(--radius-none);
  outline: none; transition: outline-color var(--dur-fast) var(--ease-out);
}
.nwl-field textarea.nwl-field__control { height: auto; padding: 12px 16px; resize: vertical; line-height: 1.5; }
.nwl-field__control:focus, .nwl-field select:focus { outline: 2px solid var(--accent); }
.nwl-field--dark .nwl-field__control, .nwl-field--dark select { border-color: transparent; }
.nwl-field--invalid .nwl-field__control { border-color: #C0392B; }
.nwl-field__hint { display: block; margin-top: 6px; font-size: 13px; color: var(--text-muted); }
.nwl-field--invalid .nwl-field__hint { color: #C0392B; }
.nwl-field--dark .nwl-field__hint { color: var(--text-inverse-muted); }

/* —— Badges ———————————————————————————————————————————— */
.nwl-badge {
  display: inline-flex; align-items: center;
  background: var(--accent); color: #fff;
  font-family: var(--font-body); font-weight: 700; font-size: 11px;
  letter-spacing: 0.05em; text-transform: uppercase; padding: 4px 9px;
}

/* —— Service / grid card ———————————————————————————————— */
.nwl-tile-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(300px,1fr));
  gap: 2px; background: var(--border);
}
.nwl-service-card {
  text-align: left; background: #fff; border: none; cursor: pointer;
  padding: 0; display: block; overflow: hidden; width: 100%;
  text-decoration: none; color: inherit;
  transition: background var(--dur-fast) var(--ease-out);
}
.nwl-service-card:hover { background: var(--surface-muted); text-decoration: none; }
.nwl-service-card__media { aspect-ratio: 16/10; overflow: hidden; }
.nwl-service-card__media img { width: 100%; height: 100%; object-fit: cover; }
.nwl-service-card__body { padding: 24px 26px 28px; }
.nwl-service-card__body h3 { font-size: 20px; margin: 0 0 8px; }
.nwl-service-card__body p { font-size: 15px; color: var(--text-muted); line-height: 1.55; margin: 0 0 14px; }
.nwl-service-card__cta { color: var(--accent); font-family: var(--font-display); font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; gap: 8px; }

/* —— Project card (photo + scrim caption) ———————————————— */
.nwl-project-card {
  position: relative; display: block; aspect-ratio: 3/4; overflow: hidden;
  background: var(--nwl-stone-200); text-decoration: none; color: inherit;
}
.nwl-project-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-slow) var(--ease-out); }
.nwl-project-card:hover img { transform: scale(1.04); }
.nwl-project-card::after { content:""; position: absolute; inset: 0; background: var(--scrim-bottom); }
.nwl-project-card__caption { position: absolute; left: 18px; right: 18px; bottom: 16px; color: #fff; z-index: 1; }
.nwl-project-card__meta { font-family: var(--font-body); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.nwl-project-card__title { font-family: var(--font-display); font-weight: 700; font-size: 18px; line-height: 1.2; }
.nwl-project-card:hover .nwl-project-card__title { text-decoration: underline; text-underline-offset: 3px; }

/* —— Review card —————————————————————————————————————— */
.nwl-review-card { background: var(--surface-dark-raised); color: #fff; padding: 22px 22px 20px; }
.nwl-review-card__head { display: flex; align-items: center; gap: 12px; }
.nwl-review-card__avatar {
  width: 44px; height: 44px; border-radius: 999px; background: var(--accent); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 700; font-size: 18px; flex: none; overflow: hidden;
}
.nwl-review-card__avatar img { width: 100%; height: 100%; object-fit: cover; }
.nwl-review-card__who { flex: 1; min-width: 0; }
.nwl-review-card__name { font-family: var(--font-display); font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nwl-review-card__client { font-size: 13px; font-weight: 600; color: var(--accent); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nwl-review-card__date { font-size: 13px; color: var(--text-inverse-muted); }
.nwl-review-card__stars { display: flex; gap: 8px; align-items: center; margin-top: 14px; }
.nwl-review-card__stars .stars { display: flex; gap: 2px; }
.nwl-review-card__quote { margin: 14px 0 0; font-size: 15px; line-height: 1.55; color: rgba(255,255,255,0.92); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
/* The 4-line clamp above keeps the homepage grid tidy; the dedicated
   Testimonials page shows every quote in full. */
.nwl-testimonials-page .nwl-review-card__quote { display: block; -webkit-line-clamp: unset; overflow: visible; }

/* —— Team card —————————————————————————————————————————— */
.nwl-team-card { background: var(--surface-muted); }
/* Frame shape and fill mode come from Customizer > Team Page > Member Cards
   (--nwl-team-photo-ratio via inc/template-tags.php + the --fit/--full
   modifier classes set in template-parts/content/team-card.php). */
.nwl-team-card__photo { position: relative; aspect-ratio: var(--nwl-team-photo-ratio, 4/5); overflow: hidden; }
.nwl-team-card__photo img { width: 100%; height: 100%; object-fit: cover; }
.nwl-team-card__photo--fit { background: var(--nwl-stone-200); }
.nwl-team-card__photo--fit img { object-fit: contain; }
.nwl-team-card__photo--full { aspect-ratio: auto; }
.nwl-team-card__photo--full img { height: auto; }
.nwl-team-card__chip {
  position: absolute; right: 0; bottom: 0; width: 32px; height: 32px;
  background: var(--surface-dark); display: flex; align-items: center; justify-content: center; color: #fff;
}
.nwl-team-card__body { padding: 18px 20px 22px; }
.nwl-team-card__name { font-family: var(--font-display); font-weight: 700; font-size: 19px; color: var(--text-heading); }
.nwl-team-card__name a { color: inherit; }
.nwl-team-card__role { margin-top: 4px; font-size: 16px; color: var(--text-soft); line-height: 1.3; }

/* Single team-member profile page styles (all 10 layouts) live in
   assets/css/team-profiles.css, enqueued right after this file. */

/* —— Stat block —————————————————————————————————————————— */
.nwl-stats { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 28px; }
.nwl-stat { display: flex; align-items: center; gap: 16px; }
.nwl-stat__value { font-family: var(--font-display); font-weight: 900; font-size: clamp(2.2rem,3vw,2.8rem); color: var(--accent); line-height: 1; }
.nwl-stat__label { font-size: 15px; line-height: 1.3; color: rgba(255,255,255,0.82); max-width: 13ch; }

/* —— Value / checklist row ————————————————————————————— */
.nwl-value-row { display: flex; gap: 14px; align-items: flex-start; }
.nwl-value-row__icon {
  flex: none; width: 24px; height: 24px; background: var(--surface-dark);
  display: flex; align-items: center; justify-content: center; margin-top: 2px; color: var(--accent);
}
.nwl-value-row__title { font-family: var(--font-display); font-weight: 700; font-size: 17px; }
.nwl-value-row__desc { font-size: 15px; color: var(--text-muted); line-height: 1.5; }

.nwl-value-card { background: #fff; border-top: 3px solid var(--accent); padding: 28px 26px 30px; }
.nwl-value-card__title { font-family: var(--font-display); font-weight: 700; font-size: 19px; margin-bottom: 10px; }
.nwl-value-card__desc { font-size: 15px; color: var(--text-muted); line-height: 1.55; margin: 0; }

/* —— Process step ———————————————————————————————————————— */
.nwl-process-card { background: #fff; padding: 30px 26px; }
.nwl-process-card__n { font-family: var(--font-display); font-weight: 900; font-size: 34px; color: var(--accent); line-height: 1; margin-bottom: 14px; }
.nwl-process-card__t { font-family: var(--font-display); font-weight: 700; font-size: 19px; margin-bottom: 8px; }
.nwl-process-card__d { font-size: 15px; color: var(--text-muted); line-height: 1.55; margin: 0; }

/* —— Filter pills (Projects) ————————————————————————————— */
.nwl-filters { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }
.nwl-filter {
  background: #fff; color: var(--text-body); border: 1px solid var(--border-strong);
  padding: 9px 18px; cursor: pointer; font-family: var(--font-display); font-weight: 600; font-size: 14px;
}
.nwl-filter.is-active { background: var(--surface-dark); color: #fff; border-color: var(--surface-dark); }

/* —— Widgets ———————————————————————————————————————————— */
/* Light stone surface (not #fff): sidebars sit on the page's white
   background, so a white card was an invisible box around the widget. */
.widget { background: var(--surface-muted); padding: 22px; margin-bottom: 24px; }
.widget:last-child { margin-bottom: 0; }
.widget-title { font-family: var(--font-display); font-weight: 700; font-size: 16px; margin: 0 0 14px; }
/* Block widgets emit real headings instead of .widget-title — scale them to
   the widget-title size so a heading block doesn't dwarf the sidebar. */
.widget h1, .widget h2, .widget h3 { font-size: 17px; margin: 0 0 14px; }
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget_search form { display: flex; }
/* font-size must stay >= 16px: iOS Safari auto-zooms the whole page on
   focus of any text input rendered smaller than that, and won't zoom back
   out on its own — the page then looks "stuck" not filling the screen
   width until the visitor manually pinches back out. */
.widget_search input[type="search"] { flex: 1; min-width: 0; height: 46px; border: 1px solid var(--border-strong); border-right: none; padding: 0 14px; font-family: var(--font-body); font-size: 16px; }
.widget_search button { width: 46px; height: 46px; background: var(--surface-dark); border: none; cursor: pointer; color: #fff; display: flex; align-items: center; justify-content: center; flex: none; }
.widget_recent_entries li, .tm-recent-post { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.widget_recent_entries li:last-child, .tm-recent-post:last-child { margin-bottom: 0; }
.tm-recent-post__thumb { width: 56px; height: 56px; object-fit: cover; flex: none; }
.tm-recent-post__title { font-family: var(--font-display); font-weight: 600; font-size: 14px; line-height: 1.3; }
.tm-recent-post__date { font-size: 12px; color: var(--text-muted); margin-top: 3px; }
.widget_categories li, .widget_archive li { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.widget_tag_cloud .tagcloud { display: flex; flex-wrap: wrap; gap: 8px; }
.widget_tag_cloud .tagcloud a { background: var(--surface-muted); padding: 6px 11px; font-size: 13px; color: var(--text-body); text-decoration: none; }
.widget-cta { background: var(--surface-dark); color: #fff; }
.widget-cta .widget-title { color: #fff; }
.widget-cta p { font-size: 14px; color: rgba(255,255,255,0.78); margin: 0 0 16px; line-height: 1.5; }
.widget-toc ul { display: grid; gap: 2px; }
.widget-toc a { display: block; padding: 8px 0; border-bottom: 1px solid var(--border); font-family: var(--font-body); font-size: 14px; color: var(--link); }
.widget-toc a:hover { color: var(--accent); text-decoration: none; }
