/* DOUR, in motion. Styles for the parts in js/more.js: quick look, build a set, your sizes and details, order
   actions, shared links, and the printed order. Same rules as store.css: one family, stadium controls, square photos. */

/* header: the set builder joins the nav when there is room for it */
.nav > a.nav-wide { display: none; }
@media (min-width: 1240px) { .nav > a.nav-wide { display: inline-flex; } }

/* the photo you tapped travels to the product page */
#gal button:first-child .ph { view-transition-name: shot; }
::view-transition-group(shot) { animation-duration: .5s; animation-timing-function: cubic-bezier(.2, .8, .2, 1); }
::view-transition-old(shot), ::view-transition-new(shot) { height: 100%; object-fit: cover; }

/* quick look: the button on a photo */
.card .quick { position: absolute; right: 8px; top: 52px; z-index: 3; width: 38px; height: 38px; background: rgba(255, 255, 255, .86); opacity: 0; transform: translateY(-6px); transition: opacity .2s, transform .3s var(--ease), background .15s; }
.card .quick svg { width: 19px; height: 19px; }
.card .quick .q-plus { display: none; stroke-width: 2.2; }
.card .quick:hover { background: #fff; }
.card .quick:focus-visible { opacity: 1; transform: none; }
@media (hover: hover) { .card:hover .quick, .card:focus-within .quick { opacity: 1; transform: none; } }
@media (max-width: 900px), (hover: none) {
  .card .quick { opacity: 1; transform: none; top: auto; bottom: 8px; background: #fff; box-shadow: 0 2px 10px rgba(0, 0, 0, .16); }
  .card .quick .q-eye { display: none; }
  .card .quick .q-plus { display: block; }
}
/* quick look: the sheet */
.ql-pics { display: grid; grid-auto-flow: column; grid-auto-columns: 64%; gap: 4px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin: -20px -24px 0; overscroll-behavior-x: contain; }
.ql-pics::-webkit-scrollbar { display: none; }
.ql-pics > * { scroll-snap-align: start; }
.ql-pics > :only-child { grid-column: 1; }
.ql-pics:has(> :only-child) { grid-auto-columns: 100%; }
.ql-pics:has(> :only-child) .ph { aspect-ratio: 1; }
.ql-bd { display: grid; gap: 14px; padding-top: 20px; }
.ql-bd .note:empty { display: none; }

/* product: the size DOUR's guide gives you, and this style with the one it goes with */
.rec { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; padding: 10px 14px; border-radius: 14px; background: color-mix(in srgb, var(--tone) 14%, #fff); }
.rec svg { width: 18px; height: 18px; margin-top: 1px; }
.both { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 14px; align-items: center; padding: 12px; border: 1.5px solid var(--rule); border-radius: 20px; }
.both:empty, #both:empty { display: none; }
.both-pics { display: flex; align-items: center; gap: 6px; }
.both-pics .ph { width: 52px; border-radius: 10px; }
.both-pics i { font-style: normal; font-weight: 700; color: var(--quiet); }
.both-bd { display: grid; gap: 2px; min-width: 0; }
.both-bd b { font-weight: 650; font-size: 14.5px; line-height: 1.25; }
.both .btn { grid-column: 1 / -1; }
.act { display: inline-flex; align-items: center; gap: 8px; justify-self: start; }
.act svg, .btn svg.i { width: 18px; height: 18px; }
.line-acts { display: inline-flex; gap: 16px; }

/* build a set */
.set-bar { display: flex; align-items: center; gap: 14px 24px; flex-wrap: wrap; padding-bottom: 22px; }
.set-fams { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.set-fams .sw { width: 30px; height: 30px; }
.set-fams .sw[aria-pressed="true"] { transform: scale(1.1); }
.set { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); gap: clamp(20px, 3vw, 48px); align-items: start; }
.reels { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
.reel { display: grid; gap: 10px; min-width: 0; align-content: start; }
.reel-hd { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding-right: 6px; }
.reel-hd b { font-size: clamp(22px, 2.1vw, 32px); font-weight: 850; font-style: italic; font-stretch: 125%; letter-spacing: -0.03em; line-height: 1; }
.reel-kinds { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; min-height: 30px; }
.reel-kinds::-webkit-scrollbar { display: none; }
.reel-kinds .chip { min-height: 30px; min-width: 0; padding: 0 11px; font-size: 12.5px; flex: none; }
.reel-win { position: relative; display: block; }
.reel-ph { position: relative; overflow: hidden; aspect-ratio: 3/4; background: var(--mist-2); touch-action: pan-y; }
.reel-ph .ph { position: absolute; inset: 0; height: 100%; aspect-ratio: auto; }
.reel-ph img { -webkit-user-drag: none; user-select: none; }
.reel-win .ic { position: absolute; background: #fff; box-shadow: 0 2px 12px rgba(0, 0, 0, .16); z-index: 2; }
.reel-win .ic:hover { background: #000; color: #fff; }
.reel-prev, .reel-next { top: 50%; margin-top: -22px; }
.reel-prev { left: 8px; }
.reel-next { right: 8px; }
.reel-look { right: 8px; top: 8px; width: 38px; height: 38px; }
.reel-look svg { width: 19px; height: 19px; }
.reel-empty { width: 100%; aspect-ratio: 3/4; display: grid; place-content: center; justify-items: center; gap: 8px; text-align: center; padding: 16px; background: repeating-linear-gradient(-58deg, var(--mist-2) 0 11px, #fff 11px 12px); font-weight: 650; font-stretch: 108%; transition: background .2s; }
.reel-empty svg { width: 44px; height: 44px; padding: 11px; border-radius: 50%; background: #000; stroke: #fff; stroke-width: 2.2; transition: transform .3s var(--snap); }
.reel-empty:hover svg { transform: scale(1.12) rotate(90deg); }
.reel-empty small { font-weight: 400; color: var(--graphite); font-size: 13px; }
.reel-bd { display: grid; gap: 9px; align-content: start; padding: 2px 6px 0 2px; min-width: 0; }
.reel-bd .row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.reel-n { font-weight: 600; font-size: 15px; line-height: 1.25; font-stretch: 104%; }
.reel-n:hover { text-decoration: underline; text-underline-offset: 3px; }
.reel-bd .sws { flex-wrap: wrap; padding: 4px; margin: -4px; }
.reel-sizes { gap: 4px; }
.reel-sizes .chip { min-height: 32px; min-width: 38px; padding: 0 9px; font-size: 12.5px; }
.set-side { gap: 14px; }
.set-lines li { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--rule); }
.set-lines .ph { border-radius: 10px; }
.set-lines b { display: block; font-weight: 600; line-height: 1.25; font-size: 14.5px; }
.set-lines .small { display: block; }
.set-lines .now-sale { font-weight: 600; }
.set-sticky { display: none; }

/* home: one set, dealt again when asked */
.setts { background: color-mix(in srgb, var(--tone) 18%, var(--mist)); transition: background .6s var(--ease); --tone: #72999D; }
.setts-in { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(24px, 5vw, 88px); align-items: center; }
.setts-bd { display: grid; gap: 18px; justify-items: start; }
.setts-pics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
.setts-pics .reel-win:nth-child(1) { translate: 0 -5%; }
.setts-pics .reel-win:nth-child(2) { translate: 0 6%; }
.setts-pics .reel-win:nth-child(3) { translate: 0 -1%; }
.setts .btn-line:hover { background: #000; color: #fff; }

/* your DOUR */
.three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
#fit-form { display: grid; gap: 14px; max-width: 640px; }
.you section { scroll-margin-top: calc(var(--hd) + 20px); min-width: 0; grid-template-columns: minmax(0, 1fr); }
.you > div { min-width: 0; }
.you .note:empty { display: none; }
.help section .you-orders { list-style: none; padding: 0; gap: 0; max-width: 760px; border-top: 1px solid var(--rule); }
.you-orders a { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--rule); color: #000; }
.you-orders a:hover b { text-decoration: underline; text-underline-offset: 3px; }
.you-orders b, .you-orders .small { display: block; }
.you-pics { display: flex; gap: 3px; }
.you-pics .ph { width: 40px; border-radius: 8px; }
.you-rail .rail-track { padding-inline: 0; scroll-padding-inline: 0; grid-auto-columns: clamp(150px, 16vw, 210px); }

/* orders: actions, a size exchange, a shared bag or list */
.order-acts { padding-top: 4px; }
.xlines { display: grid; gap: 0; }
.xline { display: grid; grid-template-columns: 60px minmax(0, 1fr); gap: 14px; padding: 14px 0; border-top: 1px solid var(--rule); }
.xline .ph { border-radius: 10px; }
.xline b, .xline .small { display: block; }
.xline .chips { margin-top: 10px; }
.xline .note { margin-top: 6px; min-height: 0; }
#x-mail[aria-disabled="true"] { background: var(--mist); border-color: var(--mist); color: var(--quiet); pointer-events: none; }
.shared { background: var(--mist-2); border-color: var(--mist-2); margin-bottom: 28px; }
.shared .grid { gap: 20px 4px; }

/* the printed order */
#print { display: none; }
@media print {
  .bar, .hd, .ft, .tabs, .tray, .toast, .scrim, .sheet, .search, .stickybuy, .skip, .order-acts { display: none !important; }
  body { padding: 0 !important; }
  body.printing > *:not(#print) { display: none !important; }
  body.printing #print { display: block; padding: 8mm; }
  .print-hd { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8mm; font-size: 12px; }
  #print .card-box { border: 0; padding: 0; }
  #print .track li::before, #print .track li::after { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
}

/* smaller screens */
@media (max-width: 1240px) {
  .set { grid-template-columns: minmax(0, 1fr); }
  .set-side { position: static; order: 0; }
}
@media (max-width: 900px) {
  .reels { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px 4px; }
  .set-bar { gap: 12px 16px; }
  .set-bar [data-set-mix] { margin-left: 0 !important; }
  .set-sticky { display: block; }
  .set-sticky .wrap { justify-content: space-between; }
  .set-sticky b { font-weight: 650; font-stretch: 106%; white-space: nowrap; }
  .set-sticky .btn { flex: 0 1 auto; white-space: normal; min-height: 46px; padding: 6px 18px; line-height: 1.2; text-align: center; }
  .setts-in { grid-template-columns: minmax(0, 1fr); }
  .setts-pics { order: -1; padding-block: 5% 6%; }
  .three { grid-template-columns: minmax(0, 1fr); }
  .you-orders a { grid-template-columns: minmax(0, 1fr) auto; }
  .you-pics { display: none; }
  .you-rail .rail-track { grid-auto-columns: 44vw; }
  .line-acts { gap: 12px; }
  .ql-pics { grid-auto-columns: 54%; }
  .ql-bd #ql-add { position: sticky; bottom: 0; z-index: 2; box-shadow: 0 10px 0 10px #fff; }
  .sec-hd:has(#set-link) { flex-wrap: wrap; align-items: flex-start; gap: 14px; }
}
