/* PC Waha UX system — shared usability improvements across buyer, store and admin journeys.
   Principles: clear location, obvious actions, scannable hierarchy and forgiving forms. */
:root {
  --bg: #081321;
  --panel: #112137;
  --panel2: #162840;
  --line: #30435b;
  --text: #f6f9fe;
  --muted: #b0c1d5;
  --blue: #57c0ff;
  --orange: #2fb5ff;
  --green: #46dea9;
  --radius: 18px;
  --focus-ring: #a0e0ff;
}
html { scroll-behavior: smooth; scroll-padding-top: 115px; }
body { line-height: 1.65; background: linear-gradient(180deg,#0c1a2c 0,#081321 480px); color: var(--text); }
main { min-height: min(60vh, 640px); }
.shell { width: min(1200px, calc(100% - 40px)); }
.section { padding-block: clamp(24px, 4.1vw, 52px); }
h1,h2,h3,h4 { line-height: 1.35; letter-spacing: 0; text-wrap: balance; }
h1 { font-size: clamp(1.85rem,3.1vw,2.55rem); }
h2 { font-size: clamp(1.27rem,2vw,1.65rem); }
h3 { font-size: 1.08rem; }
p { line-height: 1.8; }
.muted { color: var(--muted); }
::selection { background: #2665a0; color: #fff; }
:focus-visible { outline: 3px solid var(--focus-ring); outline-offset: 3px; }
a,button,summary { -webkit-tap-highlight-color: transparent; }
a { text-underline-offset: 3px; }
a:hover { color: #91d9ff; }
button,summary,select { cursor: pointer; }
button:disabled,.btn:disabled { cursor: not-allowed; opacity: .55; }
.visually-hidden { position: absolute!important; width: 1px!important; height: 1px!important; padding: 0!important; margin: -1px!important; overflow: hidden!important; clip: rect(0,0,0,0)!important; white-space: nowrap!important; border: 0!important; }
.skip-link { position: fixed; inset: 12px auto auto 12px; z-index: 1100; padding: 12px 18px; background: #fff; border-radius: 10px; color: #061b2c; transform: translateY(-140%); font-weight: 800; }
.skip-link:focus { transform: translateY(0); }
/* Consistent buttons and inputs. One saturated primary action per section. */
.btn { min-height: 44px; border: 1px solid #435772; border-radius: 12px; background: #1a3049; color: #f5f9ff; font-weight: 680; padding-inline: 17px; gap: 7px; transition: background-color .16s,border-color .16s,transform .16s; }
.btn:hover { background: #24415d; border-color: #80c4ef; color: #fff; transform: translateY(-1px); }
.btn-orange { background: linear-gradient(115deg,#28aff8,#48c4ff); border-color: #55cbff; color: #04203a; font-weight: 850; box-shadow: 0 4px 16px rgba(12,155,241,.18); }
.btn-orange:hover { background: linear-gradient(115deg,#60d0ff,#41b9fb); color: #04172a; border-color: #85ddff; }
.btn.small { min-height: 40px; }
input:not([type=checkbox]):not([type=radio]):not([type=hidden]),select,textarea {
  min-height: 46px; border-radius: 11px; border: 1px solid #455b76; background: #112137; color: #fff;
  padding: 10px 13px; font-size: max(1rem,16px); transition: border-color .16s,box-shadow .16s;
}
textarea { min-height: 115px; }
input::placeholder,textarea::placeholder { color: #a7b7ca; opacity: 1; }
input:not([type=checkbox]):not([type=radio]):focus,select:focus,textarea:focus { border-color: #5dc2ff; box-shadow: 0 0 0 3px rgba(59,178,255,.17); outline: none; }
input[type=checkbox],input[type=radio] { width: 18px; height: 18px; min-width: 18px; padding: 0; accent-color: #39bdff; }
label { color: #dfebf8; font-weight: 650; }
.field-validation-error,.validation,.validation-summary-errors { color: #ffacb8; }
.input-validation-error { border-color: #ff8194!important; }
.eyebrow { color: #a5e0ff; border: 1px solid #347ba7; background: #0d2a43; font-weight: 800; }
.panel,.admin-panel,.admin-phase5-panel,.bulk-panel,.admin-editor-section,.onboarding-form-panel,.subscription-current-card,.subscription-plan-card {
  border: 1px solid var(--line); border-radius: var(--radius); background: #102035; box-shadow: 0 12px 34px rgba(0,0,0,.10);
}
.admin-panel,.admin-phase5-panel,.admin-editor-section,.bulk-panel { padding: clamp(17px,2vw,24px); }
.empty-state { border-style: dashed; text-align: center; background: #102035; padding: clamp(26px,4vw,48px); }
.empty-state h2,.empty-state h3 { margin: 0 0 8px; }
.empty-state p { max-width: 65ch; margin: 0 auto 15px; color: var(--muted); }
.empty-state .btn { margin-top: 9px; }
.section-intro { display: flex; gap: 18px; align-items: end; justify-content: space-between; margin-bottom: 23px; }
.section-intro h2 { margin: 10px 0 5px; }
.section-intro p { margin: 0; }
.text-cta { color: #84d4ff; font-weight: 800; text-decoration: underline; white-space: nowrap; }
/* Permanent navigation with current-page indication. */
.site-header { background: rgba(7,17,30,.98); border-color: #294058; box-shadow: 0 7px 30px rgba(0,0,0,.17); }
.site-header .nav-row { height: 82px; gap: clamp(14px,2.1vw,30px); }
.brand { margin-left: 0; flex: 0 0 auto; }
.brand strong { font-size: 1.12rem; color: #fff; }
.brand-image-frame,.brand-image-frame img { width: 52px; height: 52px; }
.brand-image-frame { flex-basis: 52px; border-radius: 12px; }
.primary-nav { display: flex; gap: 5px; align-items: center; margin-inline: auto; }
.primary-nav a { padding: 9px 13px; border-radius: 10px; color: #c5d5e5; font-weight: 700; }
.primary-nav a:hover,.primary-nav a[aria-current=page] { background: #18334c; color: #fff; }
.primary-nav a[aria-current=page] { box-shadow: inset 0 -2px 0 #4abaff; }
.nav-actions { gap: 12px; margin-right: 0; white-space: nowrap; }
.nav-actions form { display: flex; }
.nav-actions .link-button,.mobile-menu .link-button { font-size: .9rem; }
.nav-dashboard-link { color: #a6e2ff; font-weight: 750; }
.mobile-menu { display: none; position: relative; }
.breadcrumb-wrap { padding-top: 15px; }
.breadcrumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: .85rem; color: #c2d0df; }
.breadcrumbs a { color: #83d0ff; text-decoration: underline; }
.breadcrumbs>span[aria-hidden] { color: #7990a8; }
.breadcrumbs [aria-current=page] { color: #eef6ff; font-weight: 750; }
.store-section-nav { display: flex; flex-wrap: nowrap; gap: 8px; padding-block: 12px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: thin; }
.store-section-nav a { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; min-height: 42px; border: 1px solid #3a5673; border-radius: 10px; background: #132941; padding: 8px 14px; color: #c6d9eb; font-weight: 700; }
.store-section-nav a[aria-current=page],.store-section-nav a:hover { border-color: #50b8fa; background: #174166; color: #fff; }
.site-footer { margin-top: 56px; background: #071321; border-top-color: #30445e; }
.footer-inner { display: flex; justify-content: space-between; gap: 30px; padding-block: 9px; }
.footer-about strong { display: block; color: #f7fbff; font-size: 1.15rem; }
.footer-about p { max-width: 46ch; margin: 5px 0 0; font-size: .87rem; color: var(--muted); }
.footer-inner nav { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; }
.footer-inner nav a { color: #a6dfff; text-decoration: underline; font-weight: 700; }
/* Homepage: search is unmistakably the first task. */
.hero-grid { min-height: 0; display: block; background-image: radial-gradient(ellipse at 13% 24%,rgba(33,150,239,.19),transparent 44%),radial-gradient(ellipse at 85% 10%,rgba(41,114,177,.14),transparent 43%); }
.hero-content { padding: clamp(35px,5.5vw,75px) 0; max-width: none; text-align: right; display: block; }
.hero-layout { display: grid; grid-template-columns: minmax(0,1.35fr) minmax(280px,.65fr); align-items: center; gap: clamp(24px,5vw,70px); }
.hero-copy { min-width: 0; }
.hero-copy h1 { font-size: clamp(2.2rem,4.3vw,4.15rem); line-height: 1.25; margin: 18px 0; letter-spacing: 0; }
.hero-copy h1 span { color: #5cc7ff; }
.hero-lead { font-size: clamp(1rem,1.35vw,1.18rem); max-width: 58ch; color: #c4d3e5; line-height: 1.9; }
.hero-search { margin: 24px 0 0; width: min(100%,690px); background: #10233a; border: 1px solid #4b637f; box-shadow: 0 14px 30px rgba(0,0,0,.24); }
.hero-search input { min-height: 50px!important; }
.hero-search .btn { min-width: 150px; }
.search-help { color: #b6cde0; font-size: .87rem; margin: 10px 4px 0; }
.hero-categories { margin-top: 28px; }
.hero-categories>span { display: block; font-size: .87rem; font-weight: 750; color: #cfdeef; margin-bottom: 9px; }
.hero-categories .category-chips { justify-content: flex-start; margin: 0; }
.category-chips a { border: 1px solid #426281; background: #14324c; color: #e3f1ff; min-height: 40px; display: inline-flex; align-items: center; border-radius: 12px; font-weight: 700; }
.category-chips a:hover { background: #225477; border-color: #8ad5ff; color: #fff; }
.hero-illustration { background: #fff; border: 1px solid #496b88; border-radius: 28px; padding: 16px; box-shadow: 0 26px 70px rgba(0,0,0,.28); overflow: hidden; }
.hero-illustration img { display: block; width: 100%; height: auto; object-fit: contain; }
.how-section { padding-top: 36px; }
.info-grid { gap: 18px; }
.info-grid article { border-color: #38516b; background: #102137; padding: 24px; box-shadow: 0 8px 26px rgba(0,0,0,.12); }
.info-grid b { width: 40px; height: 40px; background: #33b4ff; color: #082039; font-size: 1.1rem; }
.info-grid h3 { font-size: 1.23rem; margin: 16px 0 6px; }
.info-grid p { color: #bdcee0; margin: 0; }
.store-invite { display: flex; align-items: center; justify-content: space-between; gap: 25px; margin-top: 15px; padding: clamp(22px,3vw,35px); border-radius: 20px; border: 1px solid #3e6c8e; background: linear-gradient(115deg,#102f4a,#123352 80%,#114064); }
.store-invite h2 { margin: 0 0 6px; }
.store-invite p { margin: 0; color: #c4d6e8; }
/* Browse and compare: visible results, clear store and price labels. */
.search-page-intro h1 { margin: 0 0 6px; }
.search-page-intro p { margin: 0 0 20px; }
.search-page .search-bar.compact { background: #132740; border: 1px solid #4a607c; padding: 10px; }
.search-page .search-bar.compact input { min-height: 48px; font-size: 1rem; }
.filter-drawer { margin-bottom: 26px; }
.filter-drawer>.filters { border-color: #39516c; border-radius: 15px; background: #101f32; }
.filter-drawer>summary { cursor: pointer; }
.filter-field span { font-weight: 750; color: #dbe6f3; }
.results-heading { margin-top: 25px; }
.results-heading h2 { margin: 0; font-size: clamp(1.35rem,2vw,1.7rem); }
.results-heading>span,.directory-count,.inventory-result-count { background: #193650; border: 1px solid #3e6585; border-radius: 11px; font-weight: 750; color: #e0f1ff; }
.product-grid { gap: 17px; }
.product-card,.store-product-card,.directory-store-card { background: #112237; border: 1px solid #34516e; padding: 19px; box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.product-card:hover,.directory-store-card:hover { border-color: #59b8ef; box-shadow: 0 15px 34px rgba(0,0,0,.2); }
.product-card h3,.store-product-card h3 { font-size: 1.12rem; margin: 12px 0 7px; line-height: 1.5; }
.product-card h3 a,.store-product-card h3 a { text-decoration: underline; text-decoration-color: transparent; }
.product-card h3 a:hover,.store-product-card h3 a:hover { text-decoration-color: currentColor; }
.product-card .store-line { color: #b9ccdf; line-height: 1.65; }
.product-card .store-line a { color: #9bdeff; text-decoration: underline; font-weight: 700; }
.product-card .card-bottom { align-items: center; padding-top: 15px; margin-top: 15px; }
.product-card .card-bottom strong { font-size: 1.4rem; color: #fff; font-variant-numeric: tabular-nums; }
.product-card .card-bottom span { color: #c1d0df; }
.card-compare,.store-card-link { min-height: 44px; background: #183d5c; color: #aee3ff; border-color: #35698d; font-weight: 800; }
.card-compare:hover,.store-card-link:hover { background: #1b5178; color: #fff; }
.store-directory-title,.store-inventory-heading,.comparison-heading,.page-title { gap: 22px; }
.store-directory-title h1,.store-profile-copy h1,.product-summary-main h1 { font-size: clamp(1.9rem,3vw,2.5rem); }
.store-profile-v2,.product-summary-main,.offer-summary-card,.comparison-offer { border-color: #354d69; background: #112237; }
.store-profile-copy .store-description,.store-profile-copy .store-location { color: #c5d6e7; }
.store-inventory-filters,.inventory-manager-filters,.admin-filter-bar,.contact-analytics-filters { border-color: #3b536e; background: #101f33; }
.store-contact-actions .btn { min-width: 150px; }
.comparison-offer.best-offer { border-color: #55c6ff; background: #122e45; }
.comparison-price strong,.summary-price b { color: #f9fdff; font-variant-numeric: tabular-nums; }
.comparison-actions { gap: 9px; }
/* Store and admin: orientation first; numbers and actions grouped visually. */
.admin-nav-label { display: flex; align-items: baseline; gap: 12px; margin: 3px 0 9px; font-size: .92rem; font-weight: 800; color: #f2f9ff; }
.admin-nav-label span { font-size: .79rem; color: var(--muted); font-weight: 500; }
.admin-nav { padding-bottom: 14px; gap: 8px; margin-bottom: 25px; border-color: #344d67; }
.admin-nav-group { display: flex; align-items: center; flex: 0 0 auto; gap: 7px; padding-inline-end: 15px; margin-inline-end: 7px; border-inline-end: 1px solid #36526e; }
.admin-nav-group:last-child { border-inline-end: 0; margin-inline-end: 0; }
.admin-nav-group-label { color: #acd0e7; font-size: .75rem; font-weight: 850; white-space: nowrap; margin-inline-end: 4px; }
.admin-nav a { display: inline-flex; align-items: center; min-height: 43px; border-color: #35516c; border-radius: 11px; background: #14283f; color: #d2e0ef; font-weight: 700; }
.admin-nav a:hover { color: #fff; background: #204768; border-color: #59bfff; }
.admin-nav a.active { border-color: #58c1ff; background: #1c4b6e; color: #fff; font-weight: 850; box-shadow: inset 0 -2px 0 #5ecbff; }
.admin-nav a.active::before { content: ""; margin: 0; }
.admin-phase5-heading,.store-admin-heading,.page-title { margin-bottom: 27px; }
.admin-phase5-heading h1,.store-admin-heading h1,.page-title h1 { font-size: clamp(1.8rem,3vw,2.45rem); margin-top: 10px; }
.admin-phase5-heading p,.store-admin-heading p,.page-title p { font-size: 1rem; line-height: 1.75; color: var(--muted); }
.admin-kpi-grid,.store-admin-stats,.stats { gap: 13px; margin-bottom: 25px; }
.admin-kpi,.store-admin-stats article,.stats article,.subscription-usage-grid article,.admin-subscription-stats article {
  background: #14263d; border: 1px solid #36516b; border-radius: 15px; padding: 19px; box-shadow: 0 8px 23px rgba(0,0,0,.11);
}
.admin-kpi:hover { background: #193751; border-color: #6abdef; }
.admin-kpi strong,.store-admin-stats strong,.stats article strong { font-size: clamp(1.7rem,2.5vw,2.15rem); color: #fff; }
.admin-kpi span,.admin-kpi small,.store-admin-stats article>span,.store-admin-stats small { color: #c4d3e3; }
.admin-kpi.needs-attention { border-color: #b67d3a; box-shadow: inset 0 3px 0 #edb86d; }
.admin-panel-heading h2,.admin-editor-section-heading h2,.admin-phase5-panel h2,.admin-panel h2 { font-size: 1.25rem; }
.admin-panel-heading p,.admin-editor-section-heading p { font-size: .92rem; color: #b4c5d8; }
.admin-store-card,.admin-product-row,.admin-user-card,.admin-category-card,.inventory-manager-card,.subscription-store-card,.subscription-plan-admin-card {
  border: 1px solid #38536d; background: #122239; border-radius: 16px;
}
.dashboard-quick-actions>a,.admin-quick-links>a { background: #17324e; border: 1px solid #3d607e; padding: 16px; }
.dashboard-quick-actions>a:hover,.admin-quick-links>a:hover { border-color: #67caff; background: #205076; }
.dashboard-quick-actions strong,.admin-quick-links strong { color: #fff; font-size: 1rem; }
.dashboard-quick-actions span,.admin-quick-links span { color: #c4d5e7; font-size: .88rem; }
.admin-filter-bar label>span,.inventory-manager-filters label>span,.profile-form-grid label>span:first-child,.admin-form-grid label>span:first-child { color: #d3e1f0; font-size: .87rem; font-weight: 700; }
.inventory-card-title-row h2 { margin-top: 2px; }
.admin-flash { border-width: 1px; padding: 14px 18px; }
.admin-flash-error { border-color: #c65d67; }
.table-wrap { max-width: 100%; border-color: #3b526d; }
table { background: #112137; }
th { color: #e8f3ff; background: #1c334e; text-align: right; }
td { color: #e0ebf7; }
td,th { padding: 14px 13px; line-height: 1.6; }
tbody tr:nth-child(even) { background: rgba(68,103,139,.10); }
tbody tr:hover { background: rgba(56,111,167,.16); }
.page-link { min-height: 40px; border-color: #47607b; background: #152b44; color: #e5f2ff; }
.page-link.active,.page-link[aria-current=page] { border-color: #56bfff; background: #1c5278; color: #fff; }
.pager { padding-block: 6px; }
.store-profile-form,.offer-edit-form,.admin-editor-form { max-width: 100%; }
.admin-editor-actions,.profile-form-actions { padding-top: 12px; border-top: 1px solid #344c65; }
/* Responsive: no disappearing site navigation, no horizontal form overflow. */
@media (max-width: 1100px) {
  .hero-layout { grid-template-columns: minmax(0,1.2fr) minmax(235px,.65fr); gap: 22px; }
  .hero-copy h1 { font-size: clamp(2.15rem,4vw,3.3rem); }
  .site-header .nav-row { gap: 12px; }
  .primary-nav a { padding-inline: 8px; }
}
@media (max-width: 920px) {
  .site-header .nav-row { height: 72px; justify-content: space-between; }
  .site-header .primary-nav,.site-header .nav-actions { display: none!important; }
  .mobile-menu { display: block; margin-inline-start: auto; }
  .mobile-menu>summary { display: flex; align-items: center; gap: 9px; min-height: 44px; list-style: none; padding: 8px 12px; background: #163651; border: 1px solid #426986; border-radius: 11px; color: #f2f9ff; font-weight: 800; }
  .mobile-menu>summary::-webkit-details-marker { display: none; }
  .site-header .mobile-menu nav { display: grid!important; position: absolute; left: 0; top: calc(100% + 11px); width: min(315px,calc(100vw - 32px)); max-height: calc(100vh - 105px); overflow-y: auto; padding: 9px; gap: 4px; background: #10243b; border: 1px solid #4b6a87; border-radius: 15px; box-shadow: 0 25px 50px rgba(0,0,0,.4); }
  .mobile-menu nav a,.mobile-menu nav .link-button { display: block; padding: 11px 14px; border: 0; border-radius: 10px; color: #e4f1ff; font-weight: 700; text-align: right; width: 100%; min-height: 44px; background: transparent; }
  .mobile-menu nav a[aria-current=page],.mobile-menu nav a:hover { background: #1a496a; color: #fff; }
  .mobile-menu nav .mobile-menu-primary { background: #39b9ff; color: #052139; font-weight: 850; text-align: center; }
  .mobile-menu nav form { padding: 0; }
  .hero-layout { grid-template-columns: minmax(0,1fr) minmax(195px,.55fr); }
  .hero-copy h1 { font-size: clamp(1.95rem,4.1vw,2.9rem); }
  .hero-illustration { padding: 9px; border-radius: 20px; }
  .admin-kpi-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 700px) {
  .shell { width: min(100% - 28px,1200px); }
  .hero-content { padding: 31px 0 24px; }
  .hero-layout { grid-template-columns: 1fr; gap: 18px; }
  .hero-copy h1 { font-size: clamp(1.9rem,7.5vw,2.65rem); margin: 15px 0 12px; }
  .hero-lead { margin: 0; }
  .hero-illustration { width: 156px; margin: 0 auto; padding: 5px; border-radius: 16px; }
  .hero-search { margin-top: 18px; }
  .hero-categories { margin-top: 20px; }
  .how-section { padding-top: 24px; }
  .section-intro { align-items: flex-start; flex-direction: column; }
  .store-invite { flex-direction: column; align-items: stretch; }
  .store-invite .btn { width: 100%; }
  .footer-inner { flex-direction: column; }
  .footer-inner nav { gap: 15px; }
  .store-inventory-heading { align-items: flex-start; flex-wrap: wrap; }
  .admin-phase5-heading,.store-admin-heading { gap: 16px; }
  .admin-nav-label { flex-direction: column; gap: 1px; }
  .admin-panel,.admin-phase5-panel,.bulk-panel,.admin-editor-section { padding: 16px; }
  .page-title { gap: 12px; }
  .pager { position: static; background: none; border: 0; padding: 6px; }
}
@media (max-width: 440px) {
  .brand strong { font-size: 1rem; }
  .brand-image-frame,.brand-image-frame img { width: 43px; height: 43px; }
  .brand-image-frame { flex-basis: 43px; }
  .hero-search,.search-page .search-bar.compact { flex-direction: column; }
  .hero-search .btn,.search-page .search-bar.compact .btn { width: 100%; min-height: 46px; }
  .admin-kpi-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .admin-kpi,.store-admin-stats article { padding: 13px; }
  .admin-kpi strong { font-size: 1.55rem; }
  .info-grid article { padding: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,*::before,*::after { transition-duration: .01ms!important; animation-duration: .01ms!important; }
}
