/* Photochromic lens demo (app/sun.js), inside the kit's .frame */
.sun { --sun: .18; --sun-tint: #4d5358; display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-5, 24px); align-items: stretch; justify-content: stretch; padding: var(--s-6, 32px); }
.sun.frame::before { display: none; }
.sun__glasses { display: block; width: min(100%, 360px); height: auto; justify-self: center; overflow: visible; }
.sun__lens { fill: var(--sun-tint); fill-opacity: calc(.06 + var(--sun) * .82); transition: fill 200ms var(--ease, ease-out); }
.sun__rim { fill: none; stroke: var(--ink, #101618); stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; }
.sun__ctl { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: var(--s-4, 16px); font-size: var(--t-small, 14px); font-weight: 500; }
.sun__ctl input { width: 100%; height: 44px; margin: 0; accent-color: var(--action, #00787a); }
.sun__tints { display: flex; flex-wrap: wrap; gap: var(--s-2, 8px); }
.sun__tint { display: inline-flex; align-items: center; gap: var(--s-2, 8px); min-height: 44px; padding: 0 var(--s-4, 16px); border: 1px solid var(--line-strong, rgba(16, 22, 24, .2)); border-radius: var(--r-btn, 8px); background: var(--bg, #fff); color: var(--ink, #101618); font: 500 var(--t-small, 14px)/1 var(--font-text, system-ui, sans-serif); cursor: pointer; transition: border-color 150ms var(--ease, ease-out); }
.sun__tint::before { content: ""; width: 14px; height: 14px; border-radius: 50%; background: attr(data-tint type(<color>), currentColor); }
.sun__tint[data-tint="#4d5358"]::before { background: #4d5358; }
.sun__tint[data-tint="#6b4a34"]::before { background: #6b4a34; }
.sun__tint[data-tint="#2c4f7c"]::before { background: #2c4f7c; }
.sun__tint[data-tint="#2f5d4a"]::before { background: #2f5d4a; }
.sun__tint:hover { border-color: var(--ink, #101618); }
.sun__tint[aria-pressed="true"] { border-color: var(--ink, #101618); box-shadow: inset 0 0 0 1px var(--ink, #101618); }
.sun__tint:focus-visible, .sun__ctl input:focus-visible { outline: 2px solid var(--action, #00787a); outline-offset: 2px; }
@media (max-width: 639px) { .sun { padding: var(--s-5, 24px); } }
@media (prefers-reduced-motion: reduce) { .sun__lens, .sun__tint { transition: none; } }
