/* ==========================================================================
   VastuEasy — Page-specific components
   ==========================================================================
   Second stylesheet for components used by marketing pages beyond the shell
   (Services, Plans, and future pages that need the same building blocks) —
   NOT part of site.css, which is shared shell infrastructure (nav/footer/
   buttons/breadcrumb) every page depends on. Consumes tokens.css only.
   Load order: tokens.css -> site.css -> pages.css.
   ========================================================================== */

/* --------------------------------------------------------- page header */
/* Kicker + H1 + intro paragraph block used at the top of every page. */

.vc-page-header {
  max-width: var(--vc-max-width);
  margin: 0 auto;
  padding: 72px 40px 40px;
}
.vc-page-header h1 { max-width: 20em; }
.vc-page-header p { max-width: 42em; }

@media (max-width: 600px) {
  .vc-page-header { padding: 48px 20px 32px; }
}

/* Generic content section wrapper reused below the header. */
.vc-page-section {
  max-width: var(--vc-max-width);
  margin: 0 auto;
  padding: 0 40px 88px;
}
.vc-page-section--tight { padding-top: 24px; }

@media (max-width: 600px) {
  .vc-page-section { padding: 0 20px 56px; }
}

/* ------------------------------------------------------------------ chips */
/* Status/availability tags — "AVAILABLE NOW" (good) and "COMING SOON"
   (waitlist, design-spec.md §6). */

.vc-chip {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: var(--vc-radius-pill);
  padding: 4px 12px;
  margin-bottom: 12px;
}
.vc-chip-good { color: var(--vc-good); background: var(--vc-good-bg); }
.vc-chip-waitlist { color: var(--vc-accent-dark); background: var(--vc-accent-tint); }

/* ------------------------------------------------------------ service cards */

.vc-service-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}
.vc-service-card {
  background: var(--vc-panel);
  border: 1px solid var(--vc-panel-border);
  border-radius: var(--vc-radius);
  padding: 30px 28px;
}
.vc-service-card--featured {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
}
.vc-service-card--featured .vc-service-card-copy { flex: 1; min-width: 280px; }
.vc-service-card--featured .vc-btn { white-space: nowrap; }
.vc-service-card h3 { margin: 0 0 8px; }
.vc-service-card p { font-size: 15px; margin: 0; }
.vc-service-card .vc-link-arrow { margin-top: 14px; display: inline-block; }

@media (max-width: 900px) {
  .vc-service-grid { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------- info banner */
/* Non-dormant, always-visible informational strip (e.g. Plans page's
   "launching soon" notice) — distinct from the dormant tool-route status
   banner in site.css, which is hidden until phase 2. */

.vc-info-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--vc-neutral-bg);
  border: 1px solid var(--vc-panel-border);
  border-radius: var(--vc-radius);
  padding: 14px 20px;
  max-width: 46em;
}
.vc-info-banner svg { flex-shrink: 0; }
.vc-info-banner p, .vc-info-banner span { font-size: 15px; color: var(--vc-text); margin: 0; }

@media (max-width: 600px) {
  .vc-info-banner { flex-wrap: wrap; }
}

/* -------------------------------------------------------------- plans table */

.vc-plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  align-items: stretch;
}
.vc-plan-card {
  background: var(--vc-panel);
  border: 1px solid var(--vc-panel-border);
  border-top: 4px solid var(--vc-panel-border);
  border-radius: var(--vc-radius);
  display: flex;
  flex-direction: column;
}
.vc-plan-card--featured { border-top-color: var(--vc-primary); }
.vc-plan-card-header {
  padding: 26px 28px 20px;
  border-radius: var(--vc-radius-sm) var(--vc-radius-sm) 0 0;
}
.vc-plan-card--featured .vc-plan-card-header { background: var(--vc-primary-tint); }
.vc-plan-card-header h3 { margin: 0 0 6px; }
.vc-plan-tagline { font-size: 15px; color: var(--vc-text-medium); }
.vc-plan-price {
  font-family: var(--vc-font-heading);
  font-weight: 540;
  font-size: 30px;
  color: var(--vc-text-muted);
  margin-top: 14px;
}
.vc-plan-card-body {
  padding: 20px 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.vc-plan-feature {
  display: flex;
  gap: 10px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--vc-text-medium);
}
.vc-plan-feature svg { flex-shrink: 0; margin-top: 2px; }
.vc-plan-cta { margin-top: auto; padding-top: 16px; }
.vc-tag-soon {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  color: var(--vc-text-light);
  border: 1.5px solid var(--vc-divider);
  border-radius: var(--vc-radius-pill);
  padding: 10px 22px;
}
/* Razorpay checkout buttons sit in the same slot the "Coming soon" tag used,
   so they inherit .vc-plan-cta spacing and only need to fill the card width. */
.vc-plan-buy { width: 100%; justify-content: center; }
.vc-plan-buy[disabled] { opacity: 0.6; cursor: progress; }

/* Checkout progress / error / success panel under the plans grid. Empty by
   default and collapsed, so it takes no space until vc-checkout.js writes. */
.vc-checkout-status {
  margin: 22px 0 0;
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--vc-text-medium);
}
.vc-checkout-status:empty { display: none; }

/* Transient states stay understated — they are replaced within seconds. */
.vc-checkout-status[data-state="pending"] { color: var(--vc-text-medium); }

/* Success and failure both get a real panel. Paying is the single most
   important thing that happens on this page, and a thin line of green text
   under a fold-height grid was easy to miss entirely. */
.vc-checkout-status[data-state="ok"],
.vc-checkout-status[data-state="error"] {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 20px 22px;
  border-radius: var(--vc-radius);
  border: 1.5px solid;
  animation: vc-checkout-in 260ms ease-out;
}
.vc-checkout-status[data-state="ok"] {
  border-color: #2E7D32;
  background: #F1F8F2;
}
.vc-checkout-status[data-state="error"] {
  border-color: var(--vc-danger, #B3261E);
  background: #FDF3F2;
}
@keyframes vc-checkout-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}

.vc-checkout-icon {
  flex-shrink: 0;
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: 22px; line-height: 1;
}
.vc-checkout-status[data-state="ok"]    .vc-checkout-icon { background: #2E7D32; }
.vc-checkout-status[data-state="error"] .vc-checkout-icon { background: var(--vc-danger, #B3261E); }

.vc-checkout-title {
  font-family: var(--vc-font-heading);
  font-size: 19px;
  font-weight: 600;
  margin: 0 0 4px;
  color: var(--vc-text);
}
.vc-checkout-detail { margin: 0; font-size: 14.5px; color: var(--vc-text-medium); }
.vc-checkout-ref {
  display: block;
  margin-top: 8px;
  font-size: 12.5px;
  color: var(--vc-text-light);
}
.vc-checkout-actions { margin-top: 14px; }

@media (max-width: 600px) {
  .vc-checkout-status[data-state="ok"],
  .vc-checkout-status[data-state="error"] { flex-direction: column; gap: 12px; }
}

@media (max-width: 900px) {
  .vc-plans-grid { grid-template-columns: 1fr; }
  .vc-plan-card--featured { order: -1; }
}

/* Plans placeholder disclaimer + payment trust strip (design-spec.md §5.4) */

.vc-trust-strip {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-top: 28px;
  padding: 14px 20px;
  border: 1px solid var(--vc-divider);
  border-radius: var(--vc-radius);
  flex-wrap: wrap;
}
.vc-trust-strip-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--vc-text-light);
}
.vc-plans-note { font-size: 13px; color: var(--vc-text-light); margin: 18px 0 0; }

/* ------------------------------------------------------------- consulting */

.vc-consulting-list { display: flex; flex-direction: column; }
.vc-consulting-row {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 18px 0;
  border-top: 1px solid var(--vc-divider);
  flex-wrap: wrap;
}
.vc-consulting-name { font-size: 16px; font-weight: 500; flex: 1; min-width: 220px; }
.vc-consulting-price { font-size: 15px; color: var(--vc-text-light); }

/* -------------------------------------------------------------------- FAQ */
/* Native <details>/<summary> accordion, gold chevron (design-spec.md §6). */

.vc-faq-item {
  border-top: 1px solid var(--vc-divider);
  padding: 4px 0;
}
.vc-faq-item summary {
  font-size: 16px;
  font-weight: 500;
  color: var(--vc-text);
  padding: 16px 36px 16px 0;
  cursor: pointer;
  list-style: none;
  position: relative;
}
.vc-faq-item summary::-webkit-details-marker { display: none; }
.vc-faq-item summary::after {
  content: '';
  position: absolute;
  right: 4px;
  top: 22px;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--vc-primary);
  border-bottom: 2px solid var(--vc-primary);
  transform: rotate(45deg);
  transition: transform 0.15s ease;
}
.vc-faq-item[open] summary::after { transform: rotate(-135deg); top: 26px; }
.vc-faq-item p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--vc-text-medium);
  margin: 0 0 18px;
}

/* ==========================================================================
   Contact — page-specific components
   Appended by a parallel build; prefixed by page to avoid collisions with
   the rules above. Consumes tokens.css only.
   ========================================================================== */

/* ------------------------------------------------------------------ contact */

.contact-section {
  max-width: var(--vc-max-width);
  margin: 0 auto;
  padding: 72px 40px 96px;
}
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 56px;
  align-items: start;
}
.contact-copy p { max-width: 34em; }
.contact-details {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 24px 0 16px;
}
.contact-detail-link { font-size: 17px; font-weight: 500; }

.contact-form-card {
  background: var(--vc-panel);
  border: 1px solid var(--vc-panel-border);
  border-radius: var(--vc-radius);
  box-shadow: var(--vc-shadow);
  padding: 32px;
}
.contact-form { display: flex; flex-direction: column; gap: 18px; }
.contact-form-field { display: flex; flex-direction: column; gap: 6px; }
.contact-form-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--vc-text);
}

/* --------------------------------------------------------------- admin */

/* This page runs wider than the rest of the site (vc-page-header/-section
   normally cap at --vc-max-width) — a user-management table needs the room,
   especially once it's paginating thousands of rows. */
.admin-page-header, .admin-page-section { max-width: 1800px; }

.admin-gate {
  max-width: 1800px;
  margin: 0 auto;
  padding: 0 40px 48px;
}
.admin-error { color: var(--vc-danger); }

.admin-panel {
  max-width: 1800px;
  margin: 0 auto;
  padding: 0 40px 64px;
}

/* Tabbed sections. Replaced a two-column grid (users+demo left, four
   settings panels in a 360px sidebar) that had grown tall enough that
   reaching the last panel meant scrolling past every other one. One panel
   at a time, each full width — the users table in particular was being
   squeezed by the old sidebar. */
.admin-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--vc-panel-border);
  padding-bottom: 0;
}
.admin-tab {
  appearance: none;
  background: none;
  border: 1px solid transparent;
  border-bottom: none;
  border-radius: var(--vc-radius-sm) var(--vc-radius-sm) 0 0;
  padding: 10px 16px;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--vc-text-muted);
  cursor: pointer;
  margin-bottom: -1px; /* sit on the bar's border so the active tab can hide it */
}
.admin-tab:hover { color: var(--vc-text); background: var(--vc-panel); }
.admin-tab.is-active {
  background: var(--vc-panel);
  border-color: var(--vc-panel-border);
  border-bottom: 1px solid var(--vc-panel);
  color: var(--vc-text);
  font-weight: 600;
}

.admin-tabpanel {
  background: var(--vc-panel);
  border: 1px solid var(--vc-panel-border);
  border-radius: var(--vc-radius);
  padding: 24px;
}
/* [hidden] alone loses to the display:block implied above in the cascade, so
   state it explicitly — same trap as .vc-sample-loading[hidden] in the
   Sample-Demo overlay. */
.admin-tabpanel[hidden] { display: none; }
.admin-tabpanel > h2 {
  font-size: 1.15rem;
  margin: 0 0 4px;
  color: var(--vc-text);
}
.admin-tabpanel > p.vc-meta { margin: 0 0 16px; }
.admin-tabpanel .admin-table-wrap { box-shadow: none; }

@media (max-width: 700px) {
  .admin-tabs { gap: 2px; }
  .admin-tab { padding: 8px 11px; font-size: 13px; }
}

.admin-toolbar {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.admin-search-input {
  flex: 1 1 220px;
  min-width: 180px;
  padding: 8px 12px;
  border: 1px solid var(--vc-panel-border);
  border-radius: 7px;
  font-size: 14px;
  font-family: inherit;
}
.admin-status-filter {
  padding: 8px 12px;
  border: 1px solid var(--vc-panel-border);
  border-radius: 7px;
  font-size: 14px;
  font-family: inherit;
  background: #fff;
}
.admin-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 16px;
}
/* renderUsers() hides this when there's only one page, but display:flex above
   outranks [hidden]'s UA display:none (same specificity, author rule wins), so
   Prev/Next stayed visible for a single-page list. Same trap as
   .vc-sample-loading[hidden]. */
.admin-pagination[hidden] { display: none; }
.admin-table-wrap {
  background: var(--vc-panel);
  border: 1px solid var(--vc-panel-border);
  border-radius: var(--vc-radius);
  box-shadow: var(--vc-shadow);
  overflow-x: auto;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.admin-table th {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--vc-divider);
  color: var(--vc-text-muted);
  font-weight: 500;
  white-space: nowrap;
}
.admin-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--vc-divider);
  vertical-align: middle;
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-loading { text-align: center; padding: 32px 16px; color: var(--vc-text-muted); }
.admin-user-name { font-weight: 500; color: var(--vc-text); }
.admin-user-email { font-size: 12px; color: var(--vc-text-muted); }
.admin-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  text-transform: capitalize;
}
.admin-badge-good { background: var(--vc-good-bg); color: var(--vc-good); }
.admin-badge-bad { background: var(--vc-danger-bg); color: var(--vc-danger); }
.admin-badge-neutral { background: var(--vc-neutral-bg); color: var(--vc-neutral); }
.admin-limit-input {
  width: 90px;
  padding: 6px 8px;
  border: 1px solid var(--vc-panel-border);
  border-radius: 6px;
  font-size: 14px;
  font-family: inherit;
}
.admin-table .vc-btn { margin-right: 6px; }
.admin-table .vc-btn:last-child { margin-right: 0; }

/* .admin-users-col / .admin-settings-col / .admin-demo-col were the old
   two-column layout's card wrappers — every section is now its own
   .admin-tabpanel (see above), which carries that styling instead. */
.admin-demo-config, .admin-demo-create {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.admin-demo-config label, .admin-demo-create label { font-size: 13px; font-weight: 500; color: var(--vc-text); }
.admin-demo-config .admin-limit-input, .admin-demo-create .admin-limit-input { width: 90px; }
.admin-demo-created {
  background: var(--vc-good-bg);
  border: 1px solid var(--vc-good);
  border-radius: var(--vc-radius-sm);
  padding: 16px;
  margin-bottom: 16px;
}
.admin-demo-created h3 { margin: 0 0 8px; font-size: 14px; color: var(--vc-text); }
.admin-demo-created-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: monospace;
  font-size: 13px;
  padding: 4px 0;
  flex-wrap: wrap;
}
.admin-demo-created-row .vc-btn { padding: 2px 8px; font-size: 12px; }
/* Feature-flag rows (checkboxes) above the numeric limits grid. */
.admin-settings-flag {
  padding: 12px 14px;
  margin-bottom: 16px;
  border: 1px solid var(--vc-border);
  border-radius: 8px;
  background: var(--vc-surface-2, rgba(0, 0, 0, 0.02));
}
.admin-settings-flag label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--vc-text);
  cursor: pointer;
}
.admin-settings-flag input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin: 0;
  cursor: pointer;
}
.admin-settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}
.admin-settings-field label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--vc-text);
  margin-bottom: 4px;
}
.admin-settings-field .admin-limit-input { width: 100%; }
.admin-settings-help {
  font-size: 12px;
  color: var(--vc-text-muted);
  margin-top: 4px;
}
.admin-settings-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.admin-settings-saved { color: var(--vc-good); font-size: 14px; }

/* Payments & Plans tab. Each plan is a <details> — six plans' worth of
   fields expanded at once is unscannable, so they collapse to a one-line
   summary (name · price · cap · validity). */
.admin-payments-heading { margin-top: 34px; padding-top: 26px; border-top: 1px solid var(--vc-divider); }
.admin-payments-subheading { margin: 26px 0 10px; font-size: 15px; }
.admin-plan-block {
  margin-top: 16px;
  padding: 14px;
  border: 1px solid var(--vc-divider);
  border-radius: var(--vc-radius-sm);
  background: var(--vc-bg-alt);
}
.admin-plan-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  cursor: pointer;
  list-style: none;
  /* -14px pulls the hit area out to the block's padding edge, so the whole
     header row is clickable rather than just the text. */
  margin: -14px;
  padding: 14px;
}
.admin-plan-summary::-webkit-details-marker { display: none; }
.admin-plan-summary::marker { content: ''; }
.admin-plan-summary::after {
  content: '▾';
  margin-left: auto;
  color: var(--vc-primary);
  font-size: 13px;
  transition: transform .15s;
}
.admin-plan-block:not([open]) .admin-plan-summary::after { transform: rotate(-90deg); }
.admin-plan-block[open] .admin-plan-summary {
  margin-bottom: 4px;
  border-bottom: 1px solid var(--vc-divider);
}
.admin-plan-summary-name { font-weight: 600; color: var(--vc-text); font-size: 15px; }
.admin-plan-summary-meta { color: var(--vc-text-muted); font-size: 13px; }
.contact-input {
  width: 100%;
  box-sizing: border-box;
  font-family: var(--vc-font-body);
  font-size: 15px;
  color: var(--vc-text);
  background: var(--vc-bg);
  border: 1.5px solid var(--vc-panel-border);
  border-radius: var(--vc-radius-sm);
  padding: 11px 14px;
}
.contact-input::placeholder { color: var(--vc-text-light); }
.contact-input:focus-visible { outline: var(--vc-focus-ring); outline-offset: 2px; border-color: var(--vc-primary); }
.contact-textarea { resize: vertical; min-height: 120px; font-family: var(--vc-font-body); }
.contact-submit { width: 100%; margin-top: 4px; }
.contact-success {
  margin-top: 4px;
  padding: 14px 16px;
  border-radius: var(--vc-radius-sm);
  background: var(--vc-good-bg);
  color: var(--vc-good);
  font-size: 14px;
  line-height: 1.5;
}
.contact-success[hidden] { display: none; }

@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
}
@media (max-width: 600px) {
  .contact-section { padding: 48px 20px 64px; }
  .contact-form-card { padding: 24px; }
}

/* ── My Account summary (purchases.html) ─────────────────────────────────
   Shows which account is signed in, its plan, and credits remaining. Filled
   by assets/vc-purchases.js from GET /api/me. */
.vc-acct-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
}
.vc-acct-tile {
  background: var(--vc-panel);
  border: 1px solid var(--vc-panel-border);
  border-radius: var(--vc-radius);
  padding: 14px 16px;
}
.vc-acct-label {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--vc-text-muted);
  margin-bottom: 6px;
}
.vc-acct-value {
  font-size: 17px;
  font-weight: 700;
  color: var(--vc-text);
  word-break: break-word;
}
.vc-acct-of { font-size: 13px; font-weight: 400; color: var(--vc-text-muted); }
.vc-acct-note { font-size: 12px; color: var(--vc-text-muted); margin-top: 5px; }

/* The out-of-credits banner is defined in vastu-canvas/styles.css, which this
   page does not load — repeated here so the same warning can appear on the
   account page. */
.vc-limit-banner {
  background: #FBF3DA;
  border: 1px solid #E4D9B8;
  border-left: 4px solid #B8860B;
  border-radius: 10px;
  padding: 16px 18px;
  color: #5a4320;
  font-size: 13.5px;
  line-height: 1.6;
}
.vc-limit-head { font-size: 15px; font-weight: 700; color: #8A6510; margin-bottom: 6px; }
.vc-limit-banner p { margin: 0 0 10px; }
.vc-limit-cta {
  display: inline-block;
  background: #B8860B;
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  padding: 9px 16px;
  font-weight: 600;
  font-size: 13.5px;
}
.vc-limit-cta:hover { background: #8A6510; color: #fff; }
