:root {
  --bg: #08090b;
  --paper: #121417;
  --paper-2: #181b1f;
  --ink: #f4f5f6;
  --muted: #92969d;
  --line: rgba(255, 255, 255, .12);
  --blue: #2997ff;
  --green: #72d7b0;
  --daily-color: #08090b;
  --daily-color-mid: #121417;
  --daily-color-soft: #1c2025;
  --page-color: var(--daily-color);
  --page-color-mid: var(--daily-color-mid);
  --page-color-soft: var(--daily-color-soft);
  /* Keep Chinese glyphs stable across Apple, Windows, Android, and Linux. */
  --font-cjk: "Songti SC", "STSong", "SimSun", "宋体", "Noto Serif CJK SC", "Source Han Serif SC", "Noto Serif SC", serif;
  --font-body: var(--font-cjk);
  --font-display: var(--font-cjk);
  --font-data: var(--font-cjk);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
}

* { box-sizing: border-box; }
html { min-width: 320px; overflow-x: hidden; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { position: relative; margin: 0; min-width: 320px; overflow-x: hidden; overscroll-behavior-x: none; background: color-mix(in srgb, var(--page-color) 24%, #08090b); transition: background-color 700ms ease; }
body::after { position: fixed; inset: 0; z-index: 0; content: ""; pointer-events: none; background: rgba(8, 9, 11, .04); }
button, input, select { font: inherit; }
a { color: inherit; }
.is-hidden { display: none !important; }

.liquid-balance { position: fixed; inset: -12%; z-index: 0; overflow: hidden; opacity: 0; pointer-events: none; background: radial-gradient(circle at 18% 18%, color-mix(in srgb, var(--page-color-soft) 82%, transparent) 0, transparent 43%), radial-gradient(circle at 82% 68%, color-mix(in srgb, var(--page-color-mid) 78%, transparent) 0, transparent 47%), linear-gradient(135deg, color-mix(in srgb, var(--page-color) 72%, #0a0b0d) 0%, color-mix(in srgb, var(--page-color-mid) 48%, #08090b) 48%, #08090b 100%); filter: saturate(.8) brightness(.97); animation: liquid-surface-breathe 10s ease-in-out infinite; transition: opacity 900ms ease, background 900ms ease; }
.liquid-balance::before { position: absolute; inset: -22%; content: ""; background: conic-gradient(from 210deg at 50% 50%, transparent 0 18%, color-mix(in srgb, var(--page-color-soft) 64%, transparent) 30%, transparent 44% 64%, color-mix(in srgb, var(--page-color-mid) 58%, transparent) 78%, transparent 92%); filter: blur(56px); opacity: .76; transform: translate3d(-3%, -2%, 0) rotate(-8deg) scale(1.12); animation: liquid-gradient-flow 18s ease-in-out infinite alternate; }
.liquid-balance.is-active { opacity: .98; }
.liquid-balance .ink-drop { position: absolute; left: 50%; top: 50%; z-index: 1; width: clamp(18px, 2.6vw, 34px); aspect-ratio: 1; border-radius: 58% 42% 62% 38%; background: var(--ink-color, #fff); box-shadow: 0 0 34px color-mix(in srgb, var(--ink-color, #fff), transparent 35%); opacity: 0; transform: translate(-50%, -70%) scale(.18, 1.22); filter: blur(.2px); }
.liquid-balance.is-dropping .ink-drop { animation: ink-drop-fall 780ms cubic-bezier(.2,.72,.32,1) both; }
.liquid-balance.is-dropping::after { position: absolute; left: 50%; top: 50%; z-index: 0; width: min(72vw, 920px); aspect-ratio: 1; border: 1px solid color-mix(in srgb, var(--ink-color, #fff), transparent 42%); border-radius: 50%; content: ""; opacity: 0; transform: translate(-50%, -50%) scale(.06); box-shadow: 0 0 80px color-mix(in srgb, var(--ink-color, #fff), transparent 72%), inset 0 0 60px color-mix(in srgb, var(--ink-color, #fff), transparent 84%); animation: ink-ripple-spread 2200ms cubic-bezier(.16,.66,.25,1) 420ms both; }
.liquid-balance i { --wave-x: 50%; --wave-y: 50%; --wave-size: min(88vw, 1040px); position: absolute; left: var(--wave-x); top: var(--wave-y); width: var(--wave-size); aspect-ratio: 1; border-radius: 50%; background: repeating-radial-gradient(circle, transparent 0 7%, rgba(255,255,255,.14) 7.35%, rgba(255,255,255,.03) 7.8%, transparent 8.6% 15%); mix-blend-mode: soft-light; opacity: 0; transform: translate3d(-50%, -50%, 0) scale(.36); animation: liquid-water-ripple 13s cubic-bezier(.2,.55,.28,1) infinite; will-change: transform, opacity; }
.liquid-balance i:nth-child(1) { --wave-x: 18%; --wave-y: 26%; animation-delay: -1s; }.liquid-balance i:nth-child(2) { --wave-x: 74%; --wave-y: 20%; --wave-size: min(74vw, 860px); animation-delay: -5.2s; }.liquid-balance i:nth-child(3) { --wave-x: 48%; --wave-y: 70%; --wave-size: min(96vw, 1160px); animation-delay: -9.4s; }.liquid-balance i:nth-child(4) { --wave-x: 88%; --wave-y: 78%; --wave-size: min(68vw, 760px); animation-delay: -3.1s; }.liquid-balance i:nth-child(5) { --wave-x: 8%; --wave-y: 88%; --wave-size: min(72vw, 820px); animation-delay: -7.3s; }

.clothing-app { position: relative; z-index: 1; width: min(1440px, 100%); min-height: 100vh; margin: 0 auto; background: rgba(8, 9, 11, .01); }
.clothing-topbar { min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 30px; border-bottom: 1px solid var(--line); background: rgba(8, 9, 11, .24); backdrop-filter: blur(18px) saturate(.9); -webkit-backdrop-filter: blur(18px) saturate(.9); }
.clothing-brand { display: inline-flex; align-items: center; gap: 11px; min-width: 0; color: var(--ink); text-decoration: none; }
.brand-copy { display: inline-flex; align-items: baseline; gap: 6px; min-width: 0; white-space: nowrap; }
.brand-copy strong { color: var(--ink); font-family: var(--font-display); font-size: 17px; font-weight: 700; letter-spacing: 0; }
.brand-copy em { color: var(--muted); font-size: 13px; font-style: normal; font-weight: 500; }
.brand-logo-frame { --logo-main: var(--page-color); position: relative; width: 54px; height: 40px; flex: 0 0 54px; display: grid; place-items: center; border: 0; border-radius: 0; background: transparent; box-shadow: none; overflow: visible; }
.brand-logo-frame::before { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; background: linear-gradient(108deg, transparent 12%, rgba(255,255,255,0) 34%, rgba(255,255,255,.92) 49%, rgba(255,246,201,.38) 56%, rgba(255,255,255,0) 70%, transparent 88%); background-size: 220% 100%; background-position: 120% 0; mask-image: url("./wuxing-logo.png"); mask-size: contain; mask-position: center; mask-repeat: no-repeat; -webkit-mask-image: url("./wuxing-logo.png"); -webkit-mask-size: contain; -webkit-mask-position: center; -webkit-mask-repeat: no-repeat; mix-blend-mode: screen; animation: logoStrokeSweep 5.8s ease-in-out infinite; }
.brand-logo-frame::after { content: ""; position: absolute; inset: -14px; z-index: -1; background: radial-gradient(circle, color-mix(in srgb, var(--logo-main), white 8%), transparent 65%); filter: blur(10px); opacity: .34; animation: logoGlow 5s ease-in-out infinite; }
.brand-logo-art { width: 44px; height: 44px; display: block; object-fit: contain; object-position: center; filter: drop-shadow(0 0 5px rgba(238, 207, 132, .28)); }
@keyframes logoGlow { 0%,100% { transform: scale(.86); opacity: .36; } 50% { transform: scale(1.08); opacity: .8; } }
@keyframes logoStrokeSweep { 0%, 18% { background-position: 120% 0; opacity: 0; } 35% { opacity: .82; } 62%, 100% { background-position: -120% 0; opacity: 0; } }
.clothing-app[data-primary-element="火"] .brand-logo-frame { border-radius: 15px 5px 10px 5px; }
.clothing-app[data-primary-element="土"] .brand-logo-frame { border-radius: 6px; }
.clothing-app[data-primary-element="金"] .brand-logo-frame { border-radius: 4px; }
.clothing-app[data-primary-element="水"] .brand-logo-frame { border-radius: 50%; }
.clothing-brand:focus-visible { outline: 2px solid var(--blue); outline-offset: 4px; border-radius: 14px; }
.clothing-topbar nav { display: flex; gap: 8px; }
.clothing-topbar nav a { min-height: 34px; padding: 0 14px; display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; color: #c4c7cc; text-decoration: none; font-size: 12px; }
.clothing-topbar nav a:hover { color: #fff; border-color: rgba(41, 151, 255, .55); background: rgba(41, 151, 255, .1); }

.clothing-intro { min-height: 360px; padding: 72px 7vw 48px; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(360px, .8fr); align-items: end; gap: 60px; border-bottom: 1px solid var(--line); background: rgba(8, 9, 11, .02); backdrop-filter: blur(14px) saturate(.9); -webkit-backdrop-filter: blur(14px) saturate(.9); }
.eyebrow { margin: 0 0 18px; color: var(--green); font-size: 12px; font-weight: 700; }
h1 { max-width: 780px; margin: 0; font-family: var(--font-display); font-size: 76px; font-weight: 600; line-height: .98; letter-spacing: 0; }
.clothing-intro p:last-child { max-width: 620px; margin: 28px 0 0; color: var(--muted); font-size: 15px; line-height: 1.8; }
.five-color-rail { height: 240px; display: grid; grid-template-columns: repeat(5, 1fr); align-items: end; gap: 6px; }
.five-color-rail span { height: var(--base); padding: 12px 8px; display: flex; align-items: flex-end; justify-content: center; border-radius: 6px 6px 0 0; color: color-mix(in srgb, var(--tone), #fff 75%); background: var(--tone); font-family: var(--font-display); font-size: 18px; font-weight: 600; animation: five-color-balance 6.4s ease-in-out infinite; animation-delay: var(--delay); will-change: height; }
.five-color-rail span:nth-child(1) { --base: 64%; --swing: 13px; --delay: -1.1s; }
.five-color-rail span:nth-child(2) { --base: 82%; --swing: 16px; --delay: -4.6s; }
.five-color-rail span:nth-child(3) { --base: 92%; --swing: 10px; --delay: -2.8s; }
.five-color-rail span:nth-child(4) { --base: 76%; --swing: 15px; --delay: -5.7s; color: #23262a; }
.five-color-rail span:nth-child(5) { --base: 58%; --swing: 14px; --delay: -.2s; }
.five-color-rail:hover span { animation-play-state: paused; }

@keyframes five-color-balance {
  0%, 100% { height: calc(var(--base) - var(--swing)); }
  50% { height: calc(var(--base) + var(--swing)); }
}

@keyframes liquid-gradient-flow {
  0% { transform: translate3d(-4%, -3%, 0) rotate(-10deg) scale(1.08); }
  55% { transform: translate3d(5%, 2%, 0) rotate(5deg) scale(1.18); }
  100% { transform: translate3d(-1%, 5%, 0) rotate(12deg) scale(1.12); }
}

@keyframes liquid-surface-breathe {
  0%, 100% { filter: saturate(.76) brightness(.94); }
  50% { filter: saturate(.92) brightness(1.04); }
}

@keyframes liquid-water-ripple {
  0% { opacity: 0; transform: translate3d(-50%, -50%, 0) scale(.28); }
  18% { opacity: .58; }
  72% { opacity: .24; }
  100% { opacity: 0; transform: translate3d(-50%, -50%, 0) scale(1.18); }
}

@keyframes ink-drop-fall {
  0% { opacity: 0; transform: translate(-50%, -210%) scale(.16, 1.5); }
  28% { opacity: 1; transform: translate(-50%, -72%) scale(.55, 1.18); }
  52% { opacity: 1; transform: translate(-50%, -50%) scale(1.08, .74); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(2.4, .56); }
}

@keyframes ink-ripple-spread {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.06); }
  18% { opacity: .72; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1); }
}

.clothing-workbench { display: grid; grid-template-columns: minmax(300px, 390px) minmax(0, 1fr); border-bottom: 1px solid var(--line); }
.clothing-form, .clothing-results { min-width: 0; padding: 34px 30px 42px; }
.clothing-form { border-right: 1px solid var(--line); background: rgba(10, 12, 14, .14); backdrop-filter: blur(18px) saturate(.9); -webkit-backdrop-filter: blur(18px) saturate(.9); }
.clothing-results { background: rgba(13, 15, 18, .08); backdrop-filter: blur(16px) saturate(.9); -webkit-backdrop-filter: blur(16px) saturate(.9); }
.section-heading, .subheading { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.section-heading > *, .subheading > * { min-width: 0; }
.section-heading span, .subheading span { color: var(--muted); font-size: 11px; font-weight: 700; }
.section-heading strong, .subheading strong { min-width: 0; font-size: 16px; font-weight: 650; overflow-wrap: anywhere; }
.day-selector { margin-top: 22px; padding: 3px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px; border: 1px solid var(--line); border-radius: 6px; background: rgba(8, 9, 11, .28); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.day-selector button { min-height: 40px; border: 0; border-radius: 4px; color: #d7dbe0; background: transparent; font-size: 13px; font-weight: 650; cursor: pointer; transition: color 180ms ease, background 180ms ease, box-shadow 180ms ease; }
.day-selector button:hover { color: #fff; background: rgba(255, 255, 255, .06); }
.day-selector button.is-active { color: #fff; background: rgba(255, 255, 255, .13); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08); }
.day-selector button:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; }
.clothing-form > .section-heading strong { padding: 8px 14px; border: 1px solid rgba(255,255,255,.22); border-radius: 8px; color: #f4f5f6; background: rgba(255,255,255,.075); box-shadow: inset 0 1px 0 rgba(255,255,255,.14), 0 8px 20px rgba(0,0,0,.08); }
.profile-edit { min-height: 28px; padding: 3px 10px; border: 1px solid rgba(241,211,154,.34); border-radius: 999px; color: rgba(241,211,154,.9); background: transparent; font: inherit; font-size: 10px; line-height: 1; cursor: pointer; }
.profile-edit:hover { background: rgba(241,211,154,.08); }
.profile-edit:active { opacity: .72; transform: scale(.96); }
.profile-edit:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.clothing-form label { margin-top: 22px; display: grid; gap: 9px; color: #d9dbde; font-size: 13px; font-weight: 600; }
.clothing-form label[hidden] { display: none !important; }
.clothing-form input, .clothing-form select { width: 100%; min-height: 48px; padding: 0 13px; border: 1px solid var(--line); border-radius: 6px; outline: 0; color: var(--ink); background: var(--paper-2); }
.clothing-form input::placeholder { color: #686d75; }
.clothing-form input:focus, .clothing-form select:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(41, 151, 255, .14); }
.form-feedback { min-height: 22px; margin: 14px 0 0; color: var(--muted); font-size: 12px; }
.form-feedback[data-state="error"] { color: #ff8a85; }.form-feedback[data-state="success"] { color: var(--green); }.form-feedback[data-state="loading"] { color: #74b9ff; }
.calculate-button { width: 100%; min-height: 50px; border: 0; border-radius: 6px; color: #fff; background: var(--blue); font-weight: 750; cursor: pointer; }
.calculate-button:hover { background: #3ca0ff; }
.clear-profile { width: 100%; min-height: 36px; margin-top: 8px; border: 0; color: #858a92; background: transparent; font-size: 11px; cursor: pointer; }
.clear-profile:hover { color: #d7d9dd; }
.form-note { margin: 16px 0 0; color: #777c84; font-size: 11px; line-height: 1.7; }

.reminder-card { margin-top: 28px; padding: 16px; border: 1px solid rgba(114, 215, 176, .2); border-radius: 12px; background: rgba(114, 215, 176, .055); }
.reminder-heading { display: grid; gap: 6px; }
.reminder-heading span { color: var(--green); font-size: 10px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.reminder-heading strong { color: #eef7f3; font-size: 13px; line-height: 1.45; }
.reminder-toggle { margin-top: 14px !important; display: flex !important; grid-template-columns: none !important; align-items: center; gap: 9px !important; color: #d9ebe4 !important; font-size: 12px !important; cursor: pointer; }
.reminder-toggle input { position: absolute; width: 1px !important; height: 1px; opacity: 0; pointer-events: none; }
.reminder-toggle span { position: relative; width: 38px; height: 22px; flex: 0 0 38px; border-radius: 99px; background: rgba(255,255,255,.16); transition: background 180ms ease; }
.reminder-toggle span::after { position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; content: ""; background: #fff; transition: transform 180ms ease; }
.reminder-toggle input:checked + span { background: var(--green); }
.reminder-toggle input:checked + span::after { transform: translateX(16px); }
.reminder-toggle input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }
.reminder-card .form-note { margin: 10px 0 0; }

.clothing-empty { min-height: 520px; display: grid; place-content: center; justify-items: center; gap: 24px; color: var(--muted); text-align: center; }
.clothing-empty p { max-width: 360px; margin: 0; line-height: 1.7; }
.empty-spectrum { width: 220px; height: 84px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; align-items: end; }
.empty-spectrum i { height: 54%; background: #315c61; }.empty-spectrum i:nth-child(2){height:76%;background:#c64e4e}.empty-spectrum i:nth-child(3){height:100%;background:#c89b52}.empty-spectrum i:nth-child(4){height:68%;background:#e3e5e8}.empty-spectrum i:nth-child(5){height:46%;background:#274b6d}

.primary-recommendation { margin-top: 26px; display: grid; grid-template-columns: minmax(0, 1fr) 150px; border-bottom: 1px solid var(--line); }
.recommendation-copy { padding: 24px 30px 30px 0; }
.recommendation-copy > span, .secondary-colors > span, .caution-colors > span { color: var(--muted); font-size: 11px; font-weight: 700; }
.recommendation-copy h2 { margin: 8px 0 12px; font-family: var(--font-display); font-size: 42px; font-weight: 600; letter-spacing: 0; }
.recommendation-context { margin: 0 0 18px; display: flex; flex-wrap: wrap; gap: 18px 28px; }
.recommendation-context > div { display: grid; gap: 5px; }
.recommendation-context span { color: var(--muted); font-size: 10px; }
.recommendation-context strong { font-family: var(--font-display); font-size: 16px; font-weight: 600; }
.recommendation-context small { color: #7f848c; font-size: 10px; }
.recommendation-copy p { max-width: 680px; margin: 0 0 22px; color: #a9adb3; font-size: 13px; line-height: 1.75; }
.recommendation-score { min-height: 200px; display: grid; place-content: center; justify-items: center; border-left: 1px solid var(--line); background: var(--primary); color: color-mix(in srgb, var(--primary), #fff 80%); }
.recommendation-score strong { font-family: var(--font-data); font-size: 56px; font-weight: 650; letter-spacing: 0; line-height: 1; }
.recommendation-score span { margin-top: 8px; font-size: 11px; }
.secondary-colors, .caution-colors { padding: 22px 20px; border-top: 1px solid var(--line); }
.secondary-colors { grid-column: 1; padding-left: 0; }
.caution-colors { grid-column: 2; grid-row: 2; border-left: 1px solid var(--line); }
.secondary-colors strong, .caution-colors strong { margin: 7px 0 12px; display: block; font-size: 18px; }
.caution-colors p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.swatch-row { display: flex; flex-wrap: wrap; gap: 8px; }
.color-chip { min-height: 30px; padding: 0 10px 0 7px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); border-radius: 999px; color: #d8dade; font-size: 11px; }
.color-chip i { width: 16px; height: 16px; border-radius: 50%; border: 1px solid rgba(255,255,255,.18); background: var(--swatch); }

.pillar-comparison { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--line); }
.pillar-comparison > div { padding: 24px 20px 24px 0; display: grid; gap: 8px; }
.pillar-comparison > div + div { padding-left: 20px; border-left: 1px solid var(--line); }
.pillar-comparison span { color: var(--muted); font-size: 11px; }
.pillar-comparison strong { font-family: var(--font-display); font-size: 21px; font-weight: 600; letter-spacing: 0; }
.pillar-comparison small { color: #7f848c; font-size: 10px; }

.daily-classic-insight {
  padding: 22px 0 24px;
  border-bottom: 1px solid var(--line);
}

.daily-classic-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.daily-classic-heading span { color: var(--muted); font-size: 11px; font-weight: 700; }
.daily-classic-heading strong { font-family: var(--font-display); font-size: 16px; font-weight: 600; }
.daily-classic-insight blockquote { max-width: 720px; margin: 18px 0 12px; color: rgba(255,255,255,.92); font-family: var(--font-display); font-size: 16px; line-height: 1.8; text-wrap: pretty; }
.daily-classic-insight p { max-width: 680px; margin: 0 0 12px; color: rgba(255,255,255,.8); font-size: 11px; line-height: 1.7; }
.daily-classic-insight a { color: rgba(255,255,255,.72); font-size: 11px; text-underline-offset: 3px; }

.element-ranking, .outfit-suggestions, .accessory-recommendation { padding: 26px 0; border-bottom: 1px solid var(--line); }
.rank-row { min-height: 42px; display: grid; grid-template-columns: 24px 32px minmax(0, 1fr) 58px; gap: 10px; align-items: center; }
.rank-row > span, .rank-row em { color: var(--muted); font-size: 10px; font-style: normal; }.rank-row strong { font-size: 13px; }
.rank-row > div { min-width: 0; height: 8px; overflow: hidden; border: 1px solid rgba(255,255,255,.16); border-radius: 99px; background: rgba(255,255,255,.12); }.rank-row i { width: max(3px, var(--score)); height: 100%; display: block; border-radius: inherit; background: linear-gradient(105deg, color-mix(in srgb, var(--bar), white 22%) 0%, color-mix(in srgb, var(--bar), white 52%) 42%, color-mix(in srgb, var(--bar), white 28%) 64%, color-mix(in srgb, var(--bar), white 18%) 100%); background-size: 220% 100%; box-shadow: 0 0 10px color-mix(in srgb, var(--bar), white 20%); animation: rankBreath 3.2s ease-in-out var(--delay) infinite, rankFlow 5.8s ease-in-out var(--delay) infinite; will-change: background-position, opacity, filter; }
@keyframes rankBreath { 0%, 100% { opacity: .72; filter: brightness(.92); } 50% { opacity: 1; filter: brightness(1.18); } }
@keyframes rankFlow { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0 0; } }
@media (prefers-reduced-motion: reduce) { .rank-row i { animation: none; } }
.outfit-grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.outfit-grid article { min-height: 110px; padding: 22px 18px; border-bottom: 1px solid var(--line); }
.outfit-grid article + article { border-left: 1px solid var(--line); }
.outfit-grid span { display: block; margin-bottom: 12px; color: var(--muted); font-size: 10px; }.outfit-grid strong { font-size: 13px; line-height: 1.6; }
.accessory-content { min-height: 92px; padding-top: 22px; display: flex; align-items: center; gap: 18px; }.accessory-content > div:last-child { display: grid; gap: 8px; }.accessory-content strong { font-size: 15px; }.accessory-content p, .accessory-content small { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.6; }.accessory-content small { color: #777c84; }.accessory-orb { width: 48px; height: 48px; flex: 0 0 48px; border: 1px solid rgba(255,255,255,.42); border-radius: 50%; background: radial-gradient(circle at 32% 28%, rgba(255,255,255,.6), transparent 20%), var(--accessory-color); box-shadow: 0 0 24px color-mix(in srgb, var(--accessory-color), transparent 35%); animation: accessoryBreath 3.8s ease-in-out infinite; }
@keyframes accessoryBreath { 0%, 100% { transform: scale(.94); opacity: .78; } 50% { transform: scale(1.04); opacity: 1; } }

footer { min-height: 72px; padding: 0 30px; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: #71767e; font-size: 10px; }

@media (max-width: 820px) {
  .clothing-topbar { padding: 12px 16px; align-items: flex-start; flex-direction: column; }
  .clothing-topbar nav { width: 100%; }
  .clothing-topbar nav a { flex: 1; justify-content: center; }
  .clothing-intro { min-height: 520px; padding: 64px 18px 28px; grid-template-columns: 1fr; gap: 34px; }
  h1 { font-size: 54px; }
  .five-color-rail { height: 140px; }
  .clothing-workbench { grid-template-columns: 1fr; }
  .clothing-form { border-right: 0; border-bottom: 1px solid var(--line); }
  .clothing-form, .clothing-results { padding: 28px 16px 34px; }
  .primary-recommendation { grid-template-columns: 1fr 112px; }
  .recommendation-copy h2 { font-size: 34px; }
  .recommendation-context { gap: 12px 20px; }
  .recommendation-score strong { font-size: 44px; }
  .pillar-comparison { grid-template-columns: 1fr; }
  .pillar-comparison > div + div { padding-left: 0; border-top: 1px solid var(--line); border-left: 0; }
  .daily-classic-heading { align-items: flex-start; flex-direction: column; gap: 6px; }
  .daily-classic-insight blockquote { font-size: 15px; line-height: 1.75; }
  .outfit-grid { grid-template-columns: 1fr; }
  .outfit-grid article + article { border-left: 0; }
  footer { padding: 20px 16px; align-items: flex-start; flex-direction: column; }
}

@media (max-width: 480px) {
  .primary-recommendation { grid-template-columns: 1fr; }
  .recommendation-copy { padding-right: 0; }
  .recommendation-score { min-height: 112px; border-top: 1px solid var(--line); border-left: 0; }
  .secondary-colors, .caution-colors { grid-column: 1; grid-row: auto; padding-left: 0; border-left: 0; }
}

/* WeChat WebView: keep the animated color surface light enough for smooth scrolling. */
@media (max-width: 820px) {
  .clothing-topbar,
  .clothing-intro,
  .clothing-form,
  .clothing-results,
  .day-selector,
  .color-chip {
    backdrop-filter: blur(10px) saturate(115%);
    -webkit-backdrop-filter: blur(10px) saturate(115%);
  }
  .liquid-balance::before { filter: blur(32px); opacity: .58; }
  .liquid-balance i { --wave-size: min(120vw, 680px); }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .five-color-rail span { height: var(--base); animation: none; }
  .liquid-balance { animation: liquid-surface-breathe 16s ease-in-out infinite; }
  .liquid-balance::before, .liquid-balance i { animation: none; }
  .liquid-balance i { opacity: .12; transform: translate3d(-50%, -50%, 0) scale(.8); }
  .liquid-balance .ink-drop { opacity: .72; transform: translate(-50%, -50%) scale(1); }
  .liquid-balance.is-dropping::after { animation: none; opacity: .24; transform: translate(-50%, -50%) scale(.7); }
}

/* Mobile refinement: preserve hierarchy across compact and wide phone screens. */
@media (max-width: 820px) {
  .clothing-app {
    width: 100%;
    overflow-x: hidden;
  }

  .clothing-topbar {
    min-height: 60px;
    padding: 12px 16px;
    gap: 12px;
  }

  .clothing-brand {
    line-height: 1.35;
  }

  .clothing-topbar nav {
    gap: 6px;
  }

  .clothing-topbar nav a {
    min-width: 0;
    min-height: 36px;
    padding-inline: 10px;
    white-space: nowrap;
  }

  .clothing-intro {
    min-height: 0;
    padding: 48px 18px 28px;
    gap: 28px;
  }

  .clothing-intro h1 {
    max-width: 10em;
    font-size: clamp(42px, 8vw, 54px);
    line-height: 1.05;
  }

  .clothing-intro p:last-child {
    margin-top: 20px;
    font-size: 14px;
    line-height: 1.7;
  }

  .five-color-rail {
    height: 128px;
    gap: 5px;
  }

  .five-color-rail span {
    padding: 10px 5px;
    font-size: 16px;
  }

  .clothing-form,
  .clothing-results {
    padding: 26px 16px 32px;
  }

  .section-heading {
    gap: 10px;
  }

  .section-heading strong {
    font-size: 15px;
  }

  .primary-recommendation {
    margin-top: 20px;
  }

  .recommendation-copy h2 {
    font-size: clamp(32px, 8vw, 42px);
  }

  .recommendation-copy p {
    font-size: 12px;
    line-height: 1.7;
  }

  .element-ranking,
  .outfit-suggestions,
  .accessory-recommendation {
    padding-block: 22px;
  }

  .rank-row {
    grid-template-columns: 20px 28px minmax(0, 1fr) 48px;
    gap: 7px;
  }

  .outfit-grid article {
    min-height: 0;
    padding: 18px 0;
  }

  .accessory-content {
    gap: 14px;
  }
}

@media (max-width: 480px) {
  html, body { max-width: 100%; overflow-x: hidden; }
  .clothing-app, .clothing-results, .clothing-form { min-width: 0; max-width: 100%; overflow-x: hidden; }
  .section-heading, .subheading { align-items: flex-start; gap: 8px; }
  .section-heading span, .subheading span { flex: 1 1 auto; }
  .section-heading strong, .subheading strong { flex: 0 1 48%; font-size: 14px; line-height: 1.35; text-align: right; }
  .profile-edit { min-height: 26px; padding-inline: 9px; font-size: 10px; }
  .rank-row { grid-template-columns: 17px 24px minmax(0, 1fr) 42px; gap: 5px; }
  .rank-row em { white-space: nowrap; }

  .clothing-topbar {
    min-height: calc(56px + env(safe-area-inset-top));
    padding-top: env(safe-area-inset-top);
    padding-inline: max(14px, env(safe-area-inset-left)) max(14px, env(safe-area-inset-right));
  }

  .brand-logo-frame {
    width: 50px;
    height: 36px;
    flex-basis: 50px;
    border-radius: 10px;
  }

  .brand-logo-art {
    width: 40px;
    height: 40px;
  }

  .brand-copy strong {
    font-size: 16px;
    letter-spacing: -.055em;
  }

  .brand-copy em {
    font-size: 11px;
  }

  .clothing-topbar nav a {
    font-size: 11px;
  }

  .clothing-intro {
    padding: 38px 16px 24px;
    gap: 22px;
  }

  .clothing-intro h1 {
    font-size: clamp(38px, 11vw, 48px);
  }

  .clothing-intro p:last-child {
    margin-top: 16px;
    font-size: 13px;
  }

  .five-color-rail {
    height: 104px;
  }

  .five-color-rail span {
    font-size: 14px;
  }

  .clothing-form,
  .clothing-results {
    padding-inline: max(14px, env(safe-area-inset-left)) max(14px, env(safe-area-inset-right));
  }

  .day-selector button,
  .clothing-form input,
  .calculate-button {
    min-height: 46px;
  }

  .day-selector button,
  .calculate-button,
  .clear-profile { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }

  .clothing-results { padding-bottom: calc(36px + env(safe-area-inset-bottom)); }

  .pillar-comparison > div {
    padding-block: 16px;
  }

  .recommendation-copy {
    padding-block: 20px 24px;
  }

  .recommendation-score {
    min-height: 104px;
  }

  .recommendation-score strong {
    font-size: 42px;
  }

  .color-chip {
    min-height: 28px;
    padding-inline: 8px;
    font-size: 10px;
  }

  footer {
    min-height: 0;
    gap: 8px;
    padding: 18px 14px 22px;
    line-height: 1.5;
  }
}

@media (max-width: 360px) {
  .clothing-topbar {
    gap: 8px;
  }

  .clothing-brand {
    font-size: 13px;
  }

  .clothing-topbar nav a {
    padding-inline: 7px;
    font-size: 10px;
  }

  .clothing-intro h1 {
    font-size: 38px;
  }

  .five-color-rail {
    height: 92px;
    gap: 3px;
  }

  .five-color-rail span {
    font-size: 13px;
  }

  .clothing-form,
  .clothing-results {
    padding-inline: 12px;
  }

  .rank-row {
    grid-template-columns: 17px 24px minmax(0, 1fr) 42px;
    gap: 5px;
  }

  .rank-row strong {
    font-size: 12px;
  }

  .accessory-orb {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }
}

/* Compact primary result: keep the score beside the recommended color. */
@media (max-width: 480px) {
  .primary-recommendation {
    grid-template-columns: minmax(0, 1fr) 92px;
    align-items: start;
  }

  .recommendation-copy {
    grid-column: 1;
    padding-right: 10px;
  }

  .recommendation-score {
    grid-column: 2;
    grid-row: 1;
    min-height: 88px;
    margin-top: 20px;
    border-top: 0;
    border-left: 1px solid rgba(255, 255, 255, .16);
    border-radius: 8px;
  }

  .recommendation-score strong {
    font-size: 34px;
  }

  .recommendation-score span {
    margin-top: 4px;
    font-size: 10px;
  }

  .secondary-colors,
  .caution-colors {
    grid-column: 1 / -1;
  }
}

@media (max-width: 360px) {
  .primary-recommendation {
    grid-template-columns: minmax(0, 1fr) 78px;
  }

  .recommendation-copy {
    padding-right: 6px;
  }

  .recommendation-score {
    min-height: 78px;
  }

  .recommendation-score strong {
    font-size: 30px;
  }
}

/* Local Liquid Glass preview: translucent surfaces keep the daily color visible. */
:root {
  --glass-fill: rgba(255, 255, 255, .055);
  --glass-fill-strong: rgba(255, 255, 255, .085);
  --glass-edge: rgba(255, 255, 255, .18);
  --glass-edge-soft: rgba(255, 255, 255, .09);
  --glass-shadow: 0 22px 70px rgba(0, 0, 0, .22);
}

body::after {
  background: linear-gradient(120deg, rgba(255,255,255,.035), transparent 34%, rgba(255,255,255,.018) 67%, transparent);
  mix-blend-mode: screen;
}

.clothing-app {
  background: transparent;
}

.clothing-topbar,
.clothing-intro,
.clothing-form,
.clothing-results {
  border-color: var(--glass-edge-soft);
  background: var(--glass-fill);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08);
  backdrop-filter: blur(26px) saturate(145%);
  -webkit-backdrop-filter: blur(26px) saturate(145%);
}

.clothing-topbar {
  position: sticky;
  top: 0;
  z-index: 4;
  min-height: 72px;
  background: rgba(16, 18, 22, .28);
  box-shadow: inset 0 -1px 0 rgba(255,255,255,.08), 0 10px 30px rgba(0,0,0,.12);
}

.clothing-intro {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(255,255,255,.07), rgba(255,255,255,.018) 46%, rgba(255,255,255,.045));
}

.clothing-intro::before,
.clothing-form::before,
.clothing-results::before {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  background: linear-gradient(112deg, rgba(255,255,255,.10), transparent 18%, transparent 72%, rgba(255,255,255,.045));
  opacity: .56;
}

.clothing-intro > *,
.clothing-form > *,
.clothing-results > * {
  position: relative;
  z-index: 1;
}

.clothing-form,
.clothing-results {
  position: relative;
}

.clothing-form input,
.clothing-form select,
.day-selector,
.color-chip {
  border-color: var(--glass-edge);
  background: rgba(255,255,255,.065);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), inset 0 -1px 0 rgba(0,0,0,.08);
  backdrop-filter: blur(18px) saturate(135%);
  -webkit-backdrop-filter: blur(18px) saturate(135%);
}

.clothing-form input:focus,
.clothing-form select:focus {
  border-color: color-mix(in srgb, var(--blue), white 28%);
  box-shadow: 0 0 0 4px rgba(41,151,255,.12), inset 0 1px 0 rgba(255,255,255,.16);
}

.day-selector button.is-active,
.day-selector button:hover {
  background: rgba(255,255,255,.15);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 5px 16px rgba(0,0,0,.12);
}

.day-selector button:not(.is-active):hover { color: #fff; }

.primary-recommendation,
.pillar-comparison,
.element-ranking,
.outfit-suggestions,
.accessory-recommendation {
  border-color: var(--glass-edge-soft);
}

.recommendation-score {
  background: color-mix(in srgb, var(--primary) 62%, rgba(255,255,255,.12));
  box-shadow: inset 1px 0 0 rgba(255,255,255,.12), inset 0 1px 0 rgba(255,255,255,.12), var(--glass-shadow);
  backdrop-filter: blur(18px) saturate(145%);
  -webkit-backdrop-filter: blur(18px) saturate(145%);
}

.calculate-button {
  color: var(--action-color-ink, #fff);
  background: var(--action-color, var(--blue));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.24), 0 12px 28px color-mix(in srgb, var(--action-color, var(--blue)), transparent 66%);
  transition: transform 180ms ease, filter 180ms ease, background-color 500ms ease, box-shadow 500ms ease;
}

.calculate-button:hover {
  background: color-mix(in srgb, var(--action-color, var(--blue)), white 12%);
  filter: brightness(1.08) saturate(1.08);
}

.calculate-button:active {
  transform: scale(.985);
}

.five-color-rail span {
  box-shadow: inset 0 1px 0 rgba(255,255,255,.24), 0 16px 34px color-mix(in srgb, var(--tone), transparent 72%);
  filter: saturate(.88);
}

@media (max-width: 480px) {
  .clothing-topbar {
    min-height: 62px;
    background: rgba(16, 18, 22, .38);
  }

  .clothing-intro {
    background: linear-gradient(145deg, rgba(255,255,255,.065), rgba(255,255,255,.015));
  }
}

/* Keep content text readable over the moving color field. */
:root { --muted: #fff; }
.clothing-intro p:last-child,
.section-heading span,
.subheading span,
.recommendation-copy > span,
.secondary-colors > span,
.caution-colors > span,
.recommendation-copy p,
.caution-colors p,
.pillar-comparison span,
.pillar-comparison small,
.form-note,
.rank-row > span,
.rank-row em,
.outfit-grid span,
.accessory-content p,
.accessory-content small,
.clothing-empty {
  color: #fff;
}

.recommendation-copy p,
.caution-colors p,
.accessory-content p,
.accessory-content small,
.form-note {
  opacity: .92;
}

.secondary-colors > span,
.secondary-colors > strong {
  color: var(--support-color, var(--daily-color));
  text-shadow: 0 0 16px color-mix(in srgb, var(--support-color, var(--daily-color)), white 38%);
}

/* Daily rail: bounded data shifts with a quiet liquid surface. */
.five-color-rail span {
  position: relative;
  height: var(--daily-base, var(--base));
  --swing: 5px;
  overflow: hidden;
  background: var(--tone);
  transition: height 700ms cubic-bezier(.2,.8,.2,1);
}

.five-color-rail span::before {
  position: absolute;
  z-index: 0;
  inset: 0;
  content: "";
  background: linear-gradient(105deg, transparent 0%, rgba(255,255,255,.1) 45%, transparent 62%);
  background-size: 180% 100%;
  opacity: .28;
  animation: rail-minimal-flow 8s ease-in-out var(--delay) infinite;
}

.five-color-rail span::after {
  display: none;
}

.five-color-rail span { isolation: isolate; }
.five-color-rail span { text-shadow: 0 1px 12px color-mix(in srgb, var(--tone), black 24%); }

@keyframes rail-minimal-flow {
  0%, 100% { background-position: 120% 0; opacity: .16; }
  50% { background-position: -20% 0; opacity: .32; }
}

@media (prefers-reduced-motion: reduce) {
  .five-color-rail span { animation: none; transition: none; }
  .five-color-rail span::before,
  .five-color-rail span::after { animation: none; }
}

/* Final visual pass: quieter hierarchy, clearer touch feedback, and a stable mobile header. */
.clothing-topbar {
  min-height: 64px;
  padding-inline: clamp(16px, 3vw, 30px);
  background: rgba(13, 15, 18, .24);
  box-shadow: inset 0 -1px 0 rgba(255,255,255,.07), 0 8px 24px rgba(0,0,0,.1);
}

.clothing-brand {
  min-height: 44px;
  padding: 0 4px;
  border-radius: 12px;
  transition: opacity 180ms ease, transform 180ms ease;
}

.clothing-brand:hover { opacity: .92; }
.clothing-brand:active { transform: scale(.985); }

.clothing-intro {
  min-height: 320px;
  padding-top: 58px;
  background: linear-gradient(140deg, rgba(255,255,255,.065), rgba(255,255,255,.014) 52%, rgba(255,255,255,.035));
}

.clothing-intro p:last-child { max-width: 560px; }

.section-heading strong {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

.day-selector button,
.calculate-button,
.clear-profile,
.clothing-form input {
  transition: transform 180ms ease, background-color 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.day-selector button:active,
.calculate-button:active,
.clear-profile:active { transform: scale(.975); }

.day-selector button:focus-visible,
.calculate-button:focus-visible,
.clear-profile:focus-visible,
.clothing-form input:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--action-color, var(--blue)), white 34%);
  outline-offset: 3px;
}

.clothing-form input {
  min-height: 52px;
  font-size: 16px;
  letter-spacing: .02em;
}

.primary-recommendation { margin-top: 20px; }
.recommendation-score { border-radius: 12px 0 0 12px; }
.recommendation-copy h2 { line-height: 1.08; }
.daily-classic-insight { scroll-margin-top: 88px; }

@media (max-width: 820px) {
  .clothing-topbar {
    min-height: 62px;
    padding-block: 8px;
    align-items: center;
    flex-direction: row;
  }

  .clothing-intro {
    min-height: auto;
    padding: 44px 18px 24px;
    gap: 26px;
  }

  h1 { font-size: 50px; line-height: 1.02; }
  .five-color-rail { height: 124px; }
  .clothing-form, .clothing-results { padding-top: 24px; }
  .section-heading { gap: 10px; }
  .section-heading strong { font-size: 13px; }
}

@media (max-width: 480px) {
  .brand-logo-frame { width: 48px; height: 38px; flex-basis: 48px; }
  .brand-logo-art { width: 40px; height: 40px; }
  .brand-copy strong { font-size: 16px; }
  .clothing-intro { padding-top: 38px; }
  h1 { font-size: 46px; }
  .five-color-rail { height: 112px; gap: 4px; }
  .five-color-rail span { padding-inline: 4px; font-size: 14px; }
  .recommendation-score { border-radius: 12px; }
}

@media (prefers-reduced-transparency: reduce) {
  .clothing-topbar,
  .clothing-intro,
  .clothing-form,
  .clothing-results,
  .day-selector,
  .color-chip {
    background: rgba(12, 14, 17, .9);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}

.clothing-empty:has(.daily-preview) {
  min-height: 520px;
  place-content: start;
  justify-items: stretch;
  padding: 18px 0 8px;
  text-align: left;
}

.daily-preview { display: grid; gap: 30px; width: 100%; }
.daily-preview-lead { display: grid; gap: 10px; padding-bottom: 24px; border-bottom: 1px solid var(--glass-edge-soft); }
.daily-preview-lead > span { color: rgba(255,255,255,.72); font-size: 11px; font-weight: 700; }
.daily-preview-lead > strong { color: var(--daily-color); font-family: var(--font-display); font-size: clamp(34px, 4vw, 52px); font-weight: 600; line-height: 1; text-shadow: 0 0 20px color-mix(in srgb, var(--daily-color), white 35%); }
.daily-preview-ranking { display: grid; gap: 12px; }
.daily-preview-ranking .subheading { margin-bottom: 2px; }
.daily-preview-row { min-height: 34px; display: grid; grid-template-columns: 24px 30px minmax(0, 1fr); gap: 10px; align-items: center; }
.daily-preview-row > span { color: rgba(255,255,255,.54); font-size: 10px; }
.daily-preview-row > strong { font-size: 13px; }
.daily-preview-row > div { height: 7px; overflow: hidden; border: 1px solid rgba(255,255,255,.14); border-radius: 99px; background: rgba(255,255,255,.09); }
.daily-preview-row i { display: block; width: var(--score); height: 100%; border-radius: inherit; background: linear-gradient(105deg, color-mix(in srgb, var(--bar), white 22%), color-mix(in srgb, var(--bar), white 48%)); box-shadow: 0 0 12px color-mix(in srgb, var(--bar), transparent 42%); animation: rankBreath 3.2s ease-in-out infinite; }
.daily-preview > p { max-width: 540px; margin: 0; color: rgba(255,255,255,.72); font-size: 12px; line-height: 1.7; }

@media (max-width: 820px) {
  .clothing-empty:has(.daily-preview) { min-height: 0; padding-block: 8px 18px; }
  .daily-preview { gap: 24px; }
}

/* Device pass: keep the first useful result close to the input on phones and tablets. */
@media (min-width: 821px) and (max-width: 1100px) {
  .clothing-intro {
    grid-template-columns: minmax(0, 1fr) minmax(300px, .8fr);
    gap: 34px;
    padding-inline: 5vw;
  }

  .clothing-intro h1 { font-size: 64px; }
  .clothing-workbench { grid-template-columns: minmax(270px, 320px) minmax(0, 1fr); }
  .clothing-form, .clothing-results { padding-inline: 24px; }
}

@media (min-width: 821px) {
  .clothing-workbench { align-items: start; }
  .clothing-form { align-self: start; height: max-content; }
}

@media (max-width: 600px) {
  .clothing-intro {
    padding-top: 30px;
    gap: 18px;
  }

  .clothing-intro h1 { font-size: 44px; }
  .clothing-intro p:last-child { margin-top: 12px; }
  .five-color-rail { height: 96px; }
  .clothing-form, .clothing-results { padding-top: 20px; }
  .day-selector { margin-top: 16px; }
  .clothing-form label { margin-top: 18px; }
  .form-feedback { margin-top: 10px; }
  .clear-profile { margin-top: 4px; }
  .form-note { margin-top: 12px; }

  .clothing-empty:has(.daily-preview) {
    padding-top: 4px;
    padding-bottom: 10px;
  }

  .daily-preview { gap: 20px; }
  .daily-preview-lead { padding-bottom: 18px; }
  .daily-preview-lead > strong { font-size: 38px; }
  .daily-preview-ranking { gap: 9px; }
  .daily-preview-row { min-height: 30px; grid-template-columns: 20px 24px minmax(0, 1fr); gap: 7px; }
  .daily-preview-row > strong { font-size: 12px; }
  .daily-preview > p { font-size: 11px; }
}

@media (max-width: 360px) {
  .clothing-intro h1 { font-size: 38px; }
  .clothing-intro p:last-child { font-size: 12px; }
  .five-color-rail { height: 88px; }
  .five-color-rail span { font-size: 13px; }
}
