/* Shared viewport and dialog behavior. Component layouts live in their own sheets. */
:root {
  --dialog-gap:20px;
  --dialog-top-inset:max(var(--dialog-gap),env(safe-area-inset-top,0px));
  --dialog-bottom-inset:max(var(--dialog-gap),env(safe-area-inset-bottom,0px));
}
body { min-height:100dvh; }
html { scroll-padding-top:calc(var(--site-header-height,76px) + 16px); }
.header { padding-top:env(safe-area-inset-top,0px); }
.container {
  padding-left:max(20px,env(safe-area-inset-left,0px));
  padding-right:max(20px,env(safe-area-inset-right,0px));
}
.modal-backdrop {
  top:var(--dialog-viewport-top,0px);
  bottom:auto;
  height:100vh;
  height:var(--dialog-viewport-height,100dvh);
  padding:var(--dialog-top-inset) max(var(--dialog-gap),env(safe-area-inset-right,0px)) var(--dialog-bottom-inset) max(var(--dialog-gap),env(safe-area-inset-left,0px));
  overscroll-behavior:contain;
}
.modal-card {
  min-width:0;
  max-height:calc(100vh - var(--dialog-top-inset) - var(--dialog-bottom-inset));
  max-height:calc(var(--dialog-viewport-height,100dvh) - var(--dialog-top-inset) - var(--dialog-bottom-inset));
  overscroll-behavior:contain;
  scroll-padding-block:64px 20px;
  overflow-wrap:anywhere;
}
/* The close control remains reachable while the dialog's content scrolls. */
.modal-card > .modal-close {
  position:sticky;
  top:8px;
  right:auto;
  z-index:4;
  flex-shrink:0;
  width:44px;
  min-width:44px;
  height:44px;
  min-height:44px;
  margin:-8px -8px -36px auto;
}
.modal-card .modal-header { padding-right:48px; }
#mfaTitle,#accountDataTitle,#compareTitle { padding-right:48px; }
.modal-card :is(.form-group,.form-grid,.account-fields,.account-help-links) { min-width:0; }
.modal-card :is(.btn,.auth-tab-btn,.account-help-links>button) {
  min-width:0;
  max-width:100%;
  min-height:44px;
  white-space:normal;
  overflow-wrap:anywhere;
}
.auth-tab-btn { line-height:1.45; }
.modal-auth .account-help-links { display:grid; grid-template-columns:minmax(0,1fr); gap:4px; }
.account-help-links>button { text-align:center; }
.modal-card input:not([type="checkbox"]):not([type="radio"]),.modal-card textarea { font-size:max(16px,1rem); }
/* Keep the password toggle outside the text's area, including enlarged fonts. */
.password-input-wrap { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:6px; }
.password-input-wrap input { padding-right:12px!important; }
.password-input-wrap .password-visibility {
  position:static;
  transform:none;
  min-width:76px;
  min-height:48px;
  padding:8px;
  border:1px solid var(--border);
  background:#f6f7fb;
}
#mfaSetup summary { min-height:44px; padding-block:8px; }
#accountClosureMessage { resize:vertical; max-width:100%; }
.toast-container {
  right:max(16px,env(safe-area-inset-right,0px));
  bottom:max(16px,env(safe-area-inset-bottom,0px));
  max-width:calc(100% - max(16px,env(safe-area-inset-left,0px)) - max(16px,env(safe-area-inset-right,0px)));
}
.toast { min-width:0; max-width:420px; overflow-wrap:anywhere; }
.toast>span { min-width:0; }
.toast button { flex:0 0 44px; min-width:44px; min-height:44px; }
.not-found { overflow-wrap:anywhere; }
@media (max-width:700px) {
  :root { --dialog-gap:12px; }
  .modal-auth .modal-header { padding-top:48px; padding-right:0; }
  .modal-auth .auth-tabs { margin-bottom:0; }
}
@media (max-height:480px) {
  :root { --dialog-gap:8px; }
  /* Let landscape content use the full screen once the page scrolls. */
  .header { position:relative; }
  html { scroll-padding-top:16px; }
  .modal-card { scroll-padding-block:56px 12px; }
}

/* Supplier references are separate from reservable CotasPrime offers. */
.streaming-discovery { display:flex; align-items:center; justify-content:space-between; gap:16px; margin:0 0 20px; padding:16px 18px; border:1px solid #bac7ef; border-radius:10px; background:#eef2ff; color:#182230; }
.streaming-discovery>div { min-width:0; overflow-wrap:anywhere; }
.streaming-discovery strong { font-size:.9375rem; line-height:1.5; }
.streaming-discovery p { margin:4px 0 0; color:#536174; font-size:.8125rem; line-height:1.55; }
.streaming-discovery .btn { flex-shrink:0; min-height:44px; white-space:normal; text-align:center; }
.streaming-discovery a:focus-visible { outline:3px solid #244bff; outline-offset:4px; }
.catalog-section>.premium-search-results { width:100%; max-width:none; padding:16px 0 30px; margin:0; }
.premium-search-results .premium-streaming-grid { grid-template-columns:repeat(auto-fit,minmax(min(100%,270px),1fr)); }
.premium-search-results .premium-streaming-card { max-width:600px; }
.premium-show-all { margin-bottom:20px; min-height:44px; white-space:normal; }
.premium-streaming-card[hidden],.premium-show-all[hidden] { display:none; }
.premium-streaming { padding-top:56px; padding-bottom:56px; color:#182230; }
.premium-streaming-heading { max-width:850px; }
.premium-streaming-heading h2 { margin:10px 0 14px; font-size:clamp(1.5rem,3vw,2.2rem); line-height:1.2; letter-spacing:-.035em; }
.premium-streaming-heading p,.premium-streaming-date { color:#536174; line-height:1.65; }
.premium-streaming-heading p { margin:0; }
.premium-streaming-date { margin:16px 0 26px; font-size:.8125rem; }
.premium-streaming-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:18px; align-items:start; }
.premium-streaming-card { min-width:0; padding:22px; border:1px solid #dce2eb; border-radius:12px; background:#fff; overflow-wrap:anywhere; }
.premium-streaming-card .service-mark { width:48px; height:48px; margin-bottom:18px; }
.premium-streaming-card h3 { margin:0 0 20px; font-size:1.125rem; line-height:1.35; }
.premium-streaming-price { margin:0 0 6px; color:#182230; font-size:1.85rem; font-weight:800; line-height:1.15; letter-spacing:-.04em; font-variant-numeric:tabular-nums; }
.premium-streaming-price span { font-size:.875rem; font-weight:500; letter-spacing:0; color:#536174; }
.premium-streaming-price-label { margin:0 0 22px; color:#536174; font-size:.8125rem; line-height:1.55; }
.premium-streaming-description { margin:0 0 16px; font-size:.9375rem; line-height:1.65; }
.premium-streaming-features { margin:0 0 22px; padding-left:20px; color:#536174; font-size:.875rem; line-height:1.65; }
.premium-streaming-features li+li { margin-top:8px; }
.premium-streaming-card .premium-streaming-link { display:flex; align-items:center; justify-content:center; min-height:48px; min-width:44px; width:100%; padding:12px; border:1px solid #244bff; border-radius:8px; background:#244bff; color:#fff; font-size:.875rem; font-weight:650; line-height:1.45; text-align:center; text-decoration:none; }
.premium-streaming-card .premium-streaming-link:hover { background:#1738ce; border-color:#1738ce; }
.premium-streaming-rules { margin-top:18px; border-top:1px solid #dce2eb; }
.premium-streaming-rules summary { min-height:48px; padding:14px 0; color:#182230; font-size:.9375rem; font-weight:650; line-height:1.5; cursor:pointer; }
.premium-streaming-rules p { margin:0 0 12px; color:#536174; font-size:.875rem; line-height:1.65; }
.premium-streaming-sources { margin:0; padding:0; list-style:none; }
.premium-streaming-sources a { display:flex; align-items:center; min-height:44px; min-width:44px; padding:8px 0; color:#244bff; font-size:.8125rem; line-height:1.55; text-decoration:underline; text-underline-offset:3px; }
.premium-streaming-sources a:hover { color:#1738ce; }
.premium-streaming :is(a,summary):focus-visible { outline:3px solid #244bff; outline-offset:4px; }
@media (max-width:1100px) {
  .premium-streaming-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:600px) {
  .streaming-discovery { align-items:stretch; flex-direction:column; gap:10px; padding:14px; }
  .streaming-discovery .btn { align-self:flex-start; }
  .premium-streaming { padding-top:36px; padding-bottom:36px; }
  .premium-streaming-grid { grid-template-columns:minmax(0,1fr); gap:16px; }
  .premium-streaming-card { padding:22px; }
}
