/* =========================================================================
   Mobile Shell — a real phone HOME SCREEN (Android / iOS) on small devices.
   Scoped under html.mobile-shell so the desktop is untouched.
   ========================================================================= */

html.mobile-shell, html.mobile-shell body {
  margin: 0; padding: 0; height: 100%; overflow: hidden;
  background: #0a0f1e; -webkit-text-size-adjust: 100%;
}
/* Roaming Clippy pet (mobile) */
.ms-clippy {
  position: fixed; z-index: 58; left: 0; top: 60%;
  width: max(58px, 15vw); height: max(58px, 15vw); padding: 0; border: none;
  background: rgba(255,255,255,.94); border-radius: 50%; cursor: pointer; overflow: hidden;
  box-shadow: 0 6px 18px rgba(0,0,0,.38);
  transition: left 2s cubic-bezier(.4,0,.2,1), top 2s cubic-bezier(.4,0,.2,1), opacity .4s ease, transform .25s ease;
}
.ms-clippy img { width: 100%; height: 100%; object-fit: contain; padding: max(5px, 1.4vw); }
.ms-clippy:active { transform: scale(.88); }
.ms-clippy.hide { opacity: 0; pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .ms-clippy { transition: opacity .3s ease; } }

/* Scale the ROOT font-size with the viewport so every rem-based size (the
   reused app content is ~all rem) is zoom-invariant. On browsers that lay
   out at a wide viewport (e.g. 980px) and zoom out to fit, rem text would
   otherwise render tiny inside an opened app. 4.07vw == 16px at a 393px
   screen, so the normal phone look is preserved. */
html.mobile-shell { font-size: max(16px, 4.07vw); }

/* Hide all desktop chrome on phones */
html.mobile-shell #bootScreen,
html.mobile-shell #desktop,
html.mobile-shell .taskbar,
html.mobile-shell .start-menu,
html.mobile-shell .start-button,
html.mobile-shell .context-menu,
html.mobile-shell .selection-box,
html.mobile-shell #desktopClippy,
html.mobile-shell .desktop-clippy,
html.mobile-shell .skip-to-content { display: none !important; }
html.mobile-shell .ai-assistant-toggle { display: none !important; }

/* Shell scaffold (wallpaper set per-OS below) */
html.mobile-shell #mobileShell {
  position: fixed; inset: 0; display: flex; flex-direction: column;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, sans-serif;
}

/* ---------------- Status bar ---------------- */
.ms-statusbar {
  flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between;
  padding: env(safe-area-inset-top) max(16px, 5.6vw) 0;
  min-height: calc(env(safe-area-inset-top) + max(28px, 7.6vw));
  font-size: max(13px, 3.6vw); font-weight: 600; z-index: 7;
}
.ms-sb-icons { display: inline-flex; align-items: center; gap: max(5px, 1.6vw); }
.ms-sb-svg { height: max(11px, 3vw); width: auto; display: block; fill: currentColor; }
.ms-sb-time { letter-spacing: .2px; font-variant-numeric: tabular-nums; }

/* ---------------- Home (horizontal pager viewport) ---------------- */
.ms-home { flex: 1 1 auto; position: relative; overflow: hidden; min-height: 0; }
/* Absolute-positioned so each page gets a real height on iOS Safari
   (a height:100% chain through a flex column collapses there). */
.ms-pager {
  position: absolute; inset: 0; display: flex;
  transition: transform .34s cubic-bezier(.22, .61, .36, 1); will-change: transform;
}
.ms-page {
  flex: 0 0 100%; width: 100%; height: 100%;
  overflow-y: auto; -webkit-overflow-scrolling: touch;
  padding: max(6px, 2vw) max(14px, 4.6vw) 6px;
}
.ms-page-home, .ms-page-more { display: flex; flex-direction: column; }

/* Android Google search bar */
.ms-gsearch {
  display: flex; align-items: center; gap: max(8px, 2.4vw); width: 100%;
  background: rgba(255,255,255,.96); border: none; border-radius: 28px; cursor: pointer;
  padding: max(11px, 3.2vw) max(14px, 4vw); margin: max(4px, 1.5vw) 0 max(16px, 5vw); box-shadow: 0 2px 10px rgba(0,0,0,.25);
}
.ms-gsearch .ms-g svg { width: max(20px, 5.6vw); height: max(20px, 5.6vw); display: block; }
.ms-gsearch-ph { flex: 1 1 auto; text-align: left; color: #5f6368; font-size: max(.95rem, 4vw); }
.ms-gtools { display: inline-flex; align-items: center; gap: max(12px, 3.4vw); }
.ms-gtools svg { width: max(20px, 5.6vw); height: max(20px, 5.6vw); display: block; }

/* iOS widgets */
.ms-widgets { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 8px 0 20px; }
.ms-widget {
  border: none; cursor: pointer; text-align: left; border-radius: 22px; padding: 16px;
  min-height: 118px; color: #fff; display: flex; flex-direction: column;
  box-shadow: 0 6px 18px rgba(0,0,0,.18);
}
.ms-w-profile { background: linear-gradient(150deg, #2e4a78, #5478b0); }
.ms-w-profile img { width: 40px; height: 40px; border-radius: 11px; background: #fff; padding: 2px; }
.ms-w-name { font-weight: 700; font-size: .95rem; margin-top: auto; }
.ms-w-title { font-size: .72rem; opacity: .9; }
.ms-w-status { background: rgba(255,255,255,.82); color: #1c1c1e; }
.ms-w-h { font-size: .6rem; font-weight: 700; letter-spacing: .8px; color: #e0245e; }
.ms-w-big { font-size: 1.25rem; font-weight: 800; margin-top: 6px; }
.ms-w-sub { font-size: .72rem; color: #6b6b70; margin-top: auto; }

/* App icon grid (springboard). Sizes use vw so the icons scale to fill the
   actual viewport — high-DPR Android browsers report a wide CSS width, which
   made fixed-px icons look tiny. clamp() keeps them sane on any width. */
.ms-springboard { display: grid; grid-template-columns: repeat(4, 1fr); gap: max(16px, 4.6vw) max(2px, 1vw); }
.ms-app {
  background: none; border: none; cursor: pointer; padding: 0;
  display: flex; flex-direction: column; align-items: center; gap: max(6px, 1.9vw);
}
.ms-app:active { transform: scale(.92); }
.ms-app-ico {
  width: max(54px, 15vw); height: max(54px, 15vw); position: relative; display: flex; align-items: center; justify-content: center;
  color: #fff; box-shadow: 0 5px 12px rgba(0,0,0,.32);
}
.ms-app-ico svg { width: 56%; height: 56%; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ms-app-ico::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: linear-gradient(180deg, rgba(255,255,255,.30), rgba(255,255,255,0) 56%); }
.ms-app-img { padding: 7px; }
.ms-app-img img { width: 100%; height: 100%; object-fit: contain; }
.ms-app-img::after { display: none; }
.ms-badge {
  position: absolute; top: -4px; right: -4px; min-width: max(17px, 4.6vw); height: max(17px, 4.6vw); padding: 0 5px;
  border-radius: 9px; background: #ff3b30; color: #fff; font-size: max(11px, 3vw); font-weight: 700;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px rgba(0,0,0,.12);
  font-family: -apple-system, system-ui, sans-serif;
}
.ms-app-lbl {
  font-size: max(.66rem, 3vw); font-weight: 500; max-width: max(64px, 22vw); overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap;
}

/* iOS page dots */
.ms-page-dots { display: flex; gap: 7px; justify-content: center; padding: 16px 0 4px; margin-top: auto; }
.ms-page-dots i { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,.4); }
.ms-page-dots i.on { background: rgba(255,255,255,.95); }

/* ---------------- Dock ---------------- */
.ms-dock { flex: 0 0 auto; display: flex; justify-content: space-around; align-items: center; }
.ms-dock .ms-app { flex: 0 0 auto; }
.ms-dock .ms-app-lbl { display: none; }

/* Android 3-button nav bar */
.ms-navbar {
  flex: 0 0 auto; display: flex; justify-content: space-around; align-items: center;
  padding: max(6px, 1.6vw) max(36px, 9vw) calc(env(safe-area-inset-bottom) + max(6px, 1.6vw)); z-index: 6;
}
.ms-navbar button { background: none; border: none; cursor: pointer; padding: max(8px, 2.2vw); color: #fff; opacity: .92; min-width: max(44px, 12vw); min-height: max(44px, 12vw); display: flex; align-items: center; justify-content: center; }
.ms-navbar svg { width: max(22px, 6vw); height: max(22px, 6vw); display: block; fill: currentColor; }
.ms-navbar .ms-nav-back svg { fill: #fff; }

/* iOS Spotlight search pill */
.ms-ios-search {
  flex: 0 0 auto; align-self: center; display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,.28); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border: none; cursor: pointer; color: #1c1c1e; font-size: max(.88rem, 3.6vw); font-weight: 500;
  padding: max(9px, 2.6vw) max(16px, 4.6vw); border-radius: 18px; margin: 4px 0 10px; min-height: 40px;
}
.ms-ios-search svg { width: max(15px, 4vw); height: max(15px, 4vw); display: block; }

/* Home indicator (iOS) */
.ms-home-indicator {
  flex: 0 0 auto; display: flex; align-items: center; justify-content: center;
  height: calc(env(safe-area-inset-bottom) + 22px); padding-bottom: 7px; z-index: 6;
}
.ms-home-indicator span { display: block; width: max(135px, 36vw); height: max(5px, 1.4vw); border-radius: 3px; background: #000; opacity: .32; }

/* ============================================================
   Full-screen "app" sheets (reused apps[].content)
   ============================================================ */
.ms-sheet {
  position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column;
  background: #eef1f5; transform: scale(.92); opacity: 0; transform-origin: 50% 62%;
  transition: transform .32s cubic-bezier(.2,.8,.2,1), opacity .24s ease; visibility: hidden;
}
.ms-sheet.open { transform: none; opacity: 1; visibility: visible; }
@media (prefers-reduced-motion: reduce) {
  .ms-sheet, .ms-cc, .ms-cc-backdrop, .ms-dim, .ms-search { transition: none !important; }
  .ms-app:active { transform: none; }
}
.ms-sheet-head {
  flex: 0 0 auto; display: flex; align-items: center; gap: .6rem;
  padding: calc(env(safe-area-inset-top) + 12px) 12px 12px;
  background: linear-gradient(135deg, #16365c, #2171d6); color: #fff;
}
.ms-sheet-head .ms-back {
  background: rgba(255,255,255,.16); border: none; color: #fff; cursor: pointer;
  height: 38px; min-width: 38px; border-radius: 10px; padding: 0 12px; font-weight: 700; font-size: .95rem;
}
.ms-sheet-head .ms-sheet-title { font-weight: 700; font-size: 1.05rem; }
.ms-sheet-body { flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 16px 16px calc(env(safe-area-inset-bottom) + 24px); font-size: 1rem; }

/* Content normalization for reused desktop-window content */
.ms-sheet-body [style*="max-width"] { max-width: none !important; width: auto !important; }
.ms-sheet-body [style*="grid-template-columns"] { grid-template-columns: 1fr !important; }
html.mobile-shell #githubTrophies { grid-template-columns: repeat(auto-fit, minmax(92px, 1fr)) !important; }
.ms-sheet-body img, .ms-sheet-body iframe, .ms-sheet-body video, .ms-sheet-body canvas { max-width: 100% !important; height: auto; }
.ms-sheet-body iframe { width: 100% !important; aspect-ratio: 16 / 9; }
.ms-sheet-body h1 { font-size: 1.55rem !important; line-height: 1.2; }
.ms-sheet-body h2 { font-size: 1.25rem !important; }
.ms-sheet-body button, .ms-sheet-body a[role="button"], .ms-sheet-body .view-cert-btn { min-height: 44px; }
/* Content that themes via CSS variables (e.g. Contact) was built for a dark
   context; pin light-theme values so it stays readable on the light sheet. */
html.mobile-shell .ms-sheet-body {
  --text-primary: #1a2230; --text-secondary: #55657a;
  --bg-tertiary: #ffffff; --bg-secondary: #f4f6f9;
  --glass-bg: #ffffff; --glass-border: #e3e8ef;
}

/* Clippy chat reuses the existing widget, full-screen on phones */
html.mobile-shell .ai-assistant-widget {
  position: fixed !important; inset: 0 !important; width: 100% !important; height: 100% !important;
  max-width: none !important; max-height: none !important; border-radius: 0 !important;
  z-index: 75 !important; transform: none !important;
  padding-top: env(safe-area-inset-top) !important;
  padding-bottom: env(safe-area-inset-bottom) !important;
  box-sizing: border-box !important;
}
html.mobile-shell .ai-assistant-widget.hidden { display: none !important; }
html.mobile-shell #certificateModal .cert-modal-container { width: 96vw !important; max-width: 96vw !important; height: 90vh !important; }

/* ============================================================
   Android (Pixel / Material) skin
   ============================================================ */
.os-android #mobileShell {
  font-family: "Roboto", "Google Sans", system-ui, "Segoe UI", sans-serif;
  background:
    radial-gradient(120% 80% at 12% 8%, #244a8c 0%, transparent 48%),
    radial-gradient(110% 75% at 92% 96%, #145048 0%, transparent 55%),
    linear-gradient(160deg, #0c1428, #070b16);
}
.os-android .ms-statusbar { color: #fff; }
.os-android .ms-app-lbl { color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.65); font-size: max(.74rem, 3.4vw); }
/* Pixel adaptive icons are circles AND chunkier than iOS squircles — a circle
   reads smaller than a square of the same width, so size Android up. */
.os-android .ms-app-ico { width: max(66px, 18.5vw); height: max(66px, 18.5vw); border-radius: 50%; }
.os-android .ms-springboard { gap: max(20px, 5.4vw) max(2px, 1vw); }
.os-android .ms-dock { padding: 6px 14px 4px; }
.os-android .ms-page-dots i { background: rgba(255,255,255,.4); }

/* ============================================================
   iOS (Cupertino) skin
   ============================================================ */
.os-ios #mobileShell {
  font-family: -apple-system, "SF Pro Text", "SF Pro Display", system-ui, sans-serif;
  background:
    radial-gradient(120% 90% at 18% 12%, #dccab4 0%, #b69d83 42%, #8a7058 78%),
    linear-gradient(160deg, #cbb699, #8f7257);
}
.os-ios .ms-statusbar { color: #1a1410; }
.os-ios .ms-app-lbl { color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,.6), 0 0 2px rgba(0,0,0,.35); }
.os-ios .ms-app-ico { border-radius: 14px; }              /* iOS squircle */
.os-ios .ms-dock {
  margin: 0 10px; padding: 12px 10px;
  background: rgba(255,255,255,.26); -webkit-backdrop-filter: blur(22px); backdrop-filter: blur(22px);
  border-radius: 30px;
}
.os-ios .ms-dock .ms-app-ico { box-shadow: 0 3px 8px rgba(0,0,0,.22); }

/* ============================================================
   Swipe-down control center / notification shade
   ============================================================ */
.ms-dim { position: fixed; inset: 0; background: #000; opacity: 0; pointer-events: none; z-index: 90; transition: opacity .15s; }
.ms-cc-backdrop { position: fixed; inset: 0; z-index: 95; visibility: hidden; opacity: 0; transition: opacity .25s; background: rgba(0,0,0,.28); }
.ms-cc-backdrop.show { visibility: visible; opacity: 1; }

.ms-cc {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  transform: translateY(-100%); transition: transform .34s cubic-bezier(.3,1.1,.4,1);
  padding: calc(env(safe-area-inset-top) + 8px) 14px 18px;
  max-height: 94%; overflow-y: auto;
}
.ms-cc.open { transform: translateY(0); will-change: transform; }
.ms-cc-grab { display: flex; justify-content: center; padding: 2px 0 12px; touch-action: none; }
.ms-cc-grab span { width: 38px; height: 5px; border-radius: 3px; background: rgba(150,150,160,.6); }

/* Android shade + quick settings */
.ms-cc-android {
  background: rgba(22,24,30,.97); -webkit-backdrop-filter: blur(22px); backdrop-filter: blur(22px);
  color: #e8eaed; border-radius: 0 0 28px 28px; box-shadow: 0 14px 34px rgba(0,0,0,.55);
}
.ms-cc-android .ms-cc-head { display: flex; justify-content: space-between; align-items: baseline; padding: 0 8px 14px; }
.ms-cc-android .ms-cc-clock { font-size: 1.7rem; font-weight: 400; }
.ms-cc-android .ms-cc-date { font-size: .82rem; color: #9aa0a6; }
.ms-qs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.ms-qs-tile {
  display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 13px 4px;
  border: none; cursor: pointer; border-radius: 20px; background: rgba(255,255,255,.08);
  color: #c9ccd1; font-size: .6rem; font-weight: 600;
}
.ms-qs-tile .ms-qs-ico { font-size: 1.3rem; }
.ms-qs-tile.on { background: #aecbfa; color: #0b1b34; }
.ms-bright { display: flex; align-items: center; gap: 10px; padding: 4px 4px 16px; }
.ms-bright span { font-size: 1.1rem; }
.ms-bright-range { flex: 1; accent-color: #aecbfa; height: 6px; }
.ms-notif { display: flex; flex-direction: column; gap: 8px; }
.ms-notif-card { display: flex; gap: 12px; align-items: center; text-align: left; border: none; cursor: pointer; background: rgba(255,255,255,.07); border-radius: 18px; padding: 12px; color: #e8eaed; }
.ms-notif-ico { font-size: 1.45rem; flex: 0 0 auto; }
.ms-notif-t { font-weight: 700; font-size: .82rem; }
.ms-notif-b { font-size: .72rem; color: #9aa0a6; margin-top: 1px; }

/* iOS control center */
.ms-cc-ios {
  background: rgba(60,60,72,.42); -webkit-backdrop-filter: blur(30px) saturate(180%); backdrop-filter: blur(30px) saturate(180%);
  color: #fff; border-radius: 0 0 30px 30px;
}
.ms-cc-ios .ms-cc-head { text-align: right; padding: 0 10px 10px; }
.ms-cc-ios .ms-cc-clock { font-size: .9rem; font-weight: 600; opacity: .85; }
.ms-ccgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ms-cc-conn { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; place-items: center; background: rgba(255,255,255,.16); border-radius: 24px; padding: 14px; }
.ms-cc-round { width: 46px; height: 46px; border-radius: 50%; border: none; cursor: pointer; background: rgba(255,255,255,.22); color: #fff; font-size: 1.1rem; }
.ms-cc-round.on { background: #34c759; }
.ms-cc-round[data-toggle="wifi"].on, .ms-cc-round[data-toggle="bt"].on { background: #0a84ff; }
.ms-cc-stack { display: flex; flex-direction: column; gap: 12px; }
.ms-cc-sq { flex: 1; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 5px; border: none; cursor: pointer; background: rgba(255,255,255,.16); border-radius: 24px; padding: 14px; color: #fff; font-size: .74rem; font-weight: 600; }
.ms-cc-sq-ico { font-size: 1.35rem; }
.ms-cc-sliders { grid-column: 1 / -1; display: flex; gap: 12px; }
.ms-vslider { position: relative; flex: 1; height: 160px; border-radius: 28px; overflow: hidden; background: rgba(255,255,255,.16); cursor: pointer; touch-action: none; }
.ms-vs-fill { position: absolute; left: 0; right: 0; bottom: 0; background: rgba(255,255,255,.95); }
.ms-vs-ico { position: absolute; left: 0; right: 0; bottom: 14px; text-align: center; font-size: 1.25rem; mix-blend-mode: difference; }

/* ============================================================
   Search overlay (filters & launches apps)
   ============================================================ */
.ms-search {
  position: fixed; inset: 0; z-index: 85; display: flex; flex-direction: column;
  padding: calc(env(safe-area-inset-top) + 12px) 14px 0;
  opacity: 0; visibility: hidden; transition: opacity .2s ease;
}
.ms-search.open { opacity: 1; visibility: visible; }
.ms-search-bar { display: flex; align-items: center; gap: 10px; }
.ms-search-mag svg { width: 18px; height: 18px; display: block; fill: none; stroke: currentColor; stroke-width: 2; opacity: .6; }
.ms-search-input { flex: 1; border: none; background: none; outline: none; font-size: 1.05rem; color: inherit; }
.ms-search-cancel { border: none; background: none; cursor: pointer; font-weight: 600; font-size: 1rem; padding: 4px; }
.ms-search-results { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 14px 2px calc(env(safe-area-inset-bottom) + 24px); display: flex; flex-direction: column; gap: 4px; }
.ms-search-row { display: flex; align-items: center; gap: 14px; border: none; background: none; cursor: pointer; padding: 8px; border-radius: 14px; color: inherit; text-align: left; }
.ms-search-row:active { background: rgba(127,127,135,.16); }
.ms-search-row .ms-app-ico { width: 44px; height: 44px; flex: 0 0 auto; box-shadow: 0 2px 6px rgba(0,0,0,.28); }
.ms-search-row-t { display: flex; flex-direction: column; font-weight: 600; font-size: .98rem; }
.ms-search-row-t small { font-weight: 400; font-size: .76rem; opacity: .6; margin-top: 1px; }
.ms-search-empty { text-align: center; opacity: .5; padding: 36px; }

/* iOS search look (frosted light) */
.os-ios .ms-search { background: rgba(244,244,247,.86); -webkit-backdrop-filter: blur(26px) saturate(180%); backdrop-filter: blur(26px) saturate(180%); color: #1c1c1e; }
.os-ios .ms-search-bar { background: rgba(118,118,128,.12); border-radius: 12px; padding: 9px 12px; }
.os-ios .ms-search-cancel { color: #007aff; }
.os-ios .ms-search-row .ms-app-ico { border-radius: 11px; }
/* Android search look (Material light) */
.os-android .ms-search { background: #ffffff; color: #1f2430; }
.os-android .ms-search-bar { border-bottom: 1px solid #e3e8ef; padding: 6px 4px 12px; }
.os-android .ms-search-cancel { color: #1f6feb; }
.os-android .ms-search-row .ms-app-ico { border-radius: 50%; }

/* ============================================================
   Swipeable home pages — dots, Today View, Discover, At a Glance
   ============================================================ */

/* Page-indicator dots (in the fixed bottom region, above the dock) */
.ms-dots { display: flex; gap: max(8px, 2.2vw); justify-content: center; align-items: center; padding: max(8px, 2vw) 0 4px; min-height: max(22px, 6vw); }
.ms-dot {
  width: max(8px, 2.1vw); height: max(8px, 2.1vw); padding: 0; border: none; border-radius: 50%; cursor: pointer;
  background: rgba(255,255,255,.4); transition: background .2s, transform .2s;
  position: relative;
}
.ms-dot::after { content: ""; position: absolute; inset: -14px; }   /* enlarge hit target */
.ms-dot.on { background: rgba(255,255,255,.95); transform: scale(1.15); }
.os-ios .ms-dot { background: rgba(20,20,19,.28); }
.os-ios .ms-dot.on { background: rgba(20,20,19,.8); }

/* On the glance page the dock/search/home-indicator step aside (kept in flow) */
.ms-home-screen.ms-on-glance .ms-dock,
.ms-home-screen.ms-on-glance .ms-ios-search,
.ms-home-screen.ms-on-glance .ms-home-indicator { opacity: 0; visibility: hidden; }

/* ---- iOS Today View (glance page, index 0) ---- */
.ms-page-today { color: #fff; }
.ms-today { display: flex; flex-direction: column; gap: 14px; padding-bottom: 12px; }
.ms-today-h { font-size: max(1.5rem, 7.7vw); font-weight: 800; letter-spacing: -.5px; margin-top: 4px; }
.ms-today-date { font-size: max(.85rem, 3.9vw); opacity: .85; margin: -10px 0 4px; }
.ms-tw {
  width: 100%; text-align: left; border: none; cursor: pointer; color: #fff;
  background: rgba(255,255,255,.18); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px);
  border-radius: 20px; padding: max(15px, 3.8vw) max(16px, 4.1vw); box-shadow: 0 6px 18px rgba(0,0,0,.18);
}
.ms-tw-stack { display: flex; align-items: center; gap: max(13px, 3.3vw); }
.ms-tw-ava { width: max(46px, 11.7vw); height: max(46px, 11.7vw); border-radius: 13px; background: #fff; padding: 2px; flex: none; }
.ms-tw-name { font-weight: 700; font-size: max(.9rem, 4.07vw); }
.ms-tw-sub { font-size: max(.7rem, 3.1vw); opacity: .85; margin-top: 1px; }
.ms-tw-avail { font-size: max(.7rem, 3.1vw); margin-top: 5px; font-weight: 600; }
.ms-tw-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ms-tw-sm { text-align: center; }
.ms-tw-big { font-size: max(1.7rem, 8.5vw); font-weight: 800; line-height: 1; }
.ms-tw-lbl { font-size: max(.68rem, 3vw); opacity: .85; margin-top: 6px; }
.ms-tw-line { display: flex; align-items: center; gap: max(13px, 3.3vw); }
.ms-tw-ic { font-size: max(1.3rem, 6.1vw); flex: none; }
.ms-today-edit { align-self: center; font-size: max(.78rem, 3.45vw); opacity: .7; padding: 8px; }

/* ---- Weather tile (shared: iOS widget + Android Discover card) ---- */
.ms-wx-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.ms-wx-loc { font-size: max(.74rem, 3.25vw); opacity: .85; }
.ms-wx-now { font-size: max(1.5rem, 7.7vw); font-weight: 700; line-height: 1.1; }
.ms-wx-cap { font-size: max(.74rem, 3.25vw); opacity: .9; text-align: right; max-width: 45%; padding-top: 4px; }
.ms-wx-days { display: flex; justify-content: space-between; gap: 4px; }
.ms-wx-day { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: max(.66rem, 2.9vw); flex: 1 1 0; }
.ms-wx-dn { opacity: .85; }
.ms-wx-ic { font-size: max(1rem, 4.65vw); }
.ms-wx-hl { font-weight: 700; font-size: max(.62rem, 2.75vw); white-space: nowrap; }
.ms-wx-hl em { opacity: .6; font-style: normal; }

/* ---- Android At a Glance strip (top of each home page) ---- */
.ms-glance { display: flex; align-items: center; justify-content: space-between; color: #fff; padding: 2px 4px 12px; }
.ms-glance-date { font-size: max(.92rem, 4.25vw); font-weight: 600; text-shadow: 0 1px 3px rgba(0,0,0,.4); }
.ms-glance-wx { font-size: max(.92rem, 4.25vw); font-weight: 600; text-shadow: 0 1px 3px rgba(0,0,0,.4); }

/* ---- Android Discover feed (glance page, index 0) ---- */
.os-android .ms-page-glance { background: #11151d; }
.ms-discover { display: flex; flex-direction: column; gap: 12px; padding: 6px 0 16px; }
.ms-disc-head { display: flex; align-items: center; gap: 8px; color: #e8eaed; font-size: max(1rem, 4.65vw); font-weight: 600; padding: 4px 2px 2px; }
.ms-disc-g { width: 22px; height: 22px; display: inline-flex; }
.ms-disc-g svg { width: 22px; height: 22px; }
.ms-disc-card {
  width: 100%; text-align: left; border: none; cursor: pointer;
  background: #1e232c; color: #e8eaed; border-radius: 18px; padding: max(16px, 4.1vw);
  box-shadow: 0 2px 10px rgba(0,0,0,.3);
}
.ms-disc-wx { color: #e8eaed; }
.ms-disc-item { display: flex; align-items: center; gap: max(14px, 3.6vw); }
.ms-disc-ic { font-size: max(1.4rem, 6.5vw); flex: none; }
.ms-disc-t { font-weight: 600; font-size: max(.9rem, 4.07vw); }
.ms-disc-s { font-size: max(.74rem, 3.35vw); opacity: .7; margin-top: 2px; line-height: 1.35; }

@media (prefers-reduced-motion: reduce) {
  .ms-pager { transition: none !important; }
}
