    /* ── Light theme — liquid glass: wallpaper warmth bleeds through ── */
    :root, [data-theme="light"] {
      --bg: #f2f2f7;
      --wallpaper-overlay: rgba(255, 255, 255, 0.05);
      --card-bg: rgba(255, 255, 255, 0.72);
      --card-bg-strong: rgba(255, 255, 255, 0.82);
      --inner-card-bg: rgba(255, 255, 255, 0.55);
      --inner-card-border: rgba(255, 255, 255, 0.70);
      --card-border: rgba(255, 255, 255, 0.58);
      --card-highlight: inset 0 0.5px 0 rgba(255, 255, 255, 0.90);
      --card-shadow: 0 2px 28px rgba(0, 0, 0, 0.10), 0 0 0 0.5px rgba(0, 0, 0, 0.05);
      --card-blur: 28px;
      --card-saturate: 180%;
      --text-shadow: 0 1px 2px rgba(0, 0, 0, 0.10);
      --text: #000000;
      --text-secondary: #1c1c1e;
      --text-tertiary: #3a3a3c;
      --text-quaternary: #6e6e73;
      --separator: rgba(60, 60, 67, 0.18);
      --separator-opaque: #c6c6c8;
      --accent: #0060cc;
      --accent-secondary: #4240b8;
      --gold: #ff9500;
      --fill: rgba(120, 120, 128, 0.16);
      --fill-secondary: rgba(120, 120, 128, 0.10);
      --grouped-bg: rgba(255, 255, 255, 0.55);
      --tag-bg: rgba(60, 60, 67, 0.09);
      --tag-text: #3a3a3c;
      --toggle-bg: rgba(255, 255, 255, 0.52);
      --toggle-border: rgba(255, 255, 255, 0.70);
      --profile-scrim: linear-gradient(180deg, rgba(0,0,0,0.02), rgba(0,0,0,0.35));
      --specular-top: rgba(255, 255, 255, 0.22);
      --specular-gradient: linear-gradient(180deg, rgba(255,255,255,0.22) 0%, rgba(255,255,255,0.06) 32%, transparent 64%);
    }

    /* ── Dark theme — liquid glass on deep black ── */
    [data-theme="dark"] {
      --bg: #000000;
      --wallpaper-overlay: rgba(0, 0, 0, 0.32);
      --card-bg: rgba(255, 255, 255, 0.11);
      --card-bg-strong: rgba(255, 255, 255, 0.16);
      --inner-card-bg: rgba(255, 255, 255, 0.08);
      --inner-card-border: rgba(255, 255, 255, 0.14);
      --card-border: rgba(255, 255, 255, 0.18);
      --card-highlight: inset 0 0.5px 0 rgba(255, 255, 255, 0.28);
      --card-shadow: 0 2px 28px rgba(0, 0, 0, 0.40), 0 0 0 0.5px rgba(255, 255, 255, 0.07);
      --card-blur: 28px;
      --card-saturate: 180%;
      --text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
      --text: #ffffff;
      --text-secondary: rgba(255, 255, 255, 0.92);
      --text-tertiary: rgba(255, 255, 255, 0.72);
      --text-quaternary: rgba(255, 255, 255, 0.45);
      --separator: rgba(255, 255, 255, 0.12);
      --separator-opaque: #38383a;
      --accent: #0a84ff;
      --accent-secondary: #5e5ce6;
      --gold: #ff9f0a;
      --fill: rgba(255, 255, 255, 0.10);
      --fill-secondary: rgba(255, 255, 255, 0.06);
      --grouped-bg: rgba(255, 255, 255, 0.08);
      --tag-bg: rgba(255, 255, 255, 0.11);
      --tag-text: rgba(255, 255, 255, 0.78);
      --toggle-bg: rgba(255, 255, 255, 0.10);
      --toggle-border: rgba(255, 255, 255, 0.18);
      --profile-scrim: linear-gradient(180deg, rgba(0,0,0,0.10), rgba(0,0,0,0.55));
      --specular-top: rgba(255, 255, 255, 0.12);
      --specular-gradient: linear-gradient(180deg, rgba(255,255,255,0.13) 0%, rgba(255,255,255,0.03) 32%, transparent 64%);
    }

    @media (prefers-color-scheme: dark) {
      :root:not([data-theme="light"]) {
        --bg: #000000;
        --wallpaper-overlay: rgba(0, 0, 0, 0.32);
        --card-bg: rgba(255, 255, 255, 0.11);
        --card-bg-strong: rgba(255, 255, 255, 0.16);
        --inner-card-bg: rgba(255, 255, 255, 0.08);
        --inner-card-border: rgba(255, 255, 255, 0.14);
        --card-border: rgba(255, 255, 255, 0.18);
        --card-highlight: inset 0 0.5px 0 rgba(255, 255, 255, 0.28);
        --card-shadow: 0 2px 28px rgba(0, 0, 0, 0.40), 0 0 0 0.5px rgba(255, 255, 255, 0.07);
        --card-blur: 14px;
        --card-saturate: 200%;
        --text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
        --text: #ffffff;
        --text-secondary: rgba(255, 255, 255, 0.92);
        --text-tertiary: rgba(255, 255, 255, 0.72);
        --text-quaternary: rgba(255, 255, 255, 0.45);
        --separator: rgba(255, 255, 255, 0.12);
        --separator-opaque: #38383a;
        --accent: #0a84ff;
        --accent-secondary: #5e5ce6;
        --gold: #ff9f0a;
        --fill: rgba(255, 255, 255, 0.10);
        --fill-secondary: rgba(255, 255, 255, 0.06);
        --grouped-bg: rgba(255, 255, 255, 0.08);
        --tag-bg: rgba(255, 255, 255, 0.11);
        --tag-text: rgba(255, 255, 255, 0.78);
        --toggle-bg: rgba(255, 255, 255, 0.10);
        --toggle-border: rgba(255, 255, 255, 0.18);
        --profile-scrim: linear-gradient(180deg, rgba(0,0,0,0.10), rgba(0,0,0,0.55));
        --specular-top: rgba(255, 255, 255, 0.12);
        --specular-gradient: linear-gradient(180deg, rgba(255,255,255,0.13) 0%, rgba(255,255,255,0.03) 32%, transparent 64%);
      }
    }

    * { box-sizing: border-box; margin: 0; padding: 0; }

    html {
      scroll-behavior: smooth;
      background-color: var(--bg);
    }

    /* ── Sharp page wallpaper ── */
    .blur-bg {
      position: fixed;
      inset: 0;
      background: url('../images/background_bold.jpg') center / cover no-repeat;
      filter: brightness(0.72) saturate(1.05);
      z-index: -1;
      pointer-events: none;
    }

    /* Light-mode: slightly brighter */
    [data-theme="light"] .blur-bg {
      filter: brightness(0.82) saturate(0.88);
    }

    @media (prefers-color-scheme: light) {
      :root:not([data-theme="dark"]) .blur-bg {
        filter: brightness(0.82) saturate(0.88);
      }
    }

    body {
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', system-ui, sans-serif;
      background: var(--wallpaper-overlay);
      color: var(--text);
      line-height: 1.58;
      font-weight: 450;
      font-size: 0.94rem;
      min-height: 100vh;
      -webkit-font-smoothing: antialiased;
      -moz-osx-font-smoothing: grayscale;
      transition: background 0.3s ease, color 0.3s ease;
      text-shadow: var(--text-shadow);
    }

    a { color: var(--accent); text-decoration: none; font-weight: 500; }
    a:hover { text-decoration: underline; }

    /* ── Controls toolbar ── */
    .controls {
      position: fixed;
      top: 16px;
      right: 16px;
      z-index: 1000;
      display: flex;
      align-items: center;
      gap: 3px;
      background: var(--toggle-bg);
      border: 1px solid var(--toggle-border);
      border-radius: 14px;
      padding: 4px;
      box-shadow: var(--card-shadow);
      backdrop-filter: blur(20px) saturate(180%);
      -webkit-backdrop-filter: blur(20px) saturate(180%);
    }

    .layout-btn,
    .theme-toggle {
      width: 32px;
      height: 32px;
      border-radius: 10px;
      border: none;
      background: transparent;
      color: var(--text-quaternary);
      cursor: pointer;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 12px;
      font-weight: 800;
      text-decoration: none;
      transition: background 0.15s, color 0.15s;
    }

    .layout-btn:hover,
    .theme-toggle:hover {
      background: var(--fill);
      color: var(--accent);
    }

    .layout-btn.active {
      background: var(--accent);
      color: #ffffff;
    }

    .ctrl-divider {
      width: 1px;
      height: 18px;
      background: var(--toggle-border);
      margin: 0 2px;
    }

    /* ── iOS-style card container — centred column ── */
    .ios-stack {
      max-width: 780px;
      margin: 0 auto;
      padding: 24px 16px 48px;
      display: grid;
      gap: 14px;
    }

    /* ────────────────────────────────────────────────────────────────
       Liquid glass card system
       ──────────────────────────────────────────────────────────────── */

    /*
     * Outer card — a transparent shell that clips children to rounded rect.
     * The glass effect lives entirely in .glass-layer so that card content
     * (text, images) is rendered on a separate stacking layer and stays sharp.
     */
    .ios-card {
      position: relative;
      border-radius: 22px;
      overflow: hidden;
      /* Depth shadow lives on the outer card; highlights on the glass layer */
      box-shadow: var(--card-shadow);
    }

    /*
     * Glass layer — positioned absolute, fills the card.
     *
     * Rendering pipeline:
     *   1. backdrop-filter: blur(20px) saturate(200%)
     *      → captures and blurs the wallpaper visible through the card
     *   2. background: var(--card-bg)
     *      → tints the blurred backdrop with a translucent wash
     *   3. filter: url(#liquid-glass)
     *      → applies the SVG filter chain to the COMPOSITED result above:
     *         feTurbulence → feDisplacementMap → feGaussianBlur
     *         creating organic lens distortion + appearance softening
     *   4. ::after gradient — specular highlight along the top edge
     *
     * Content (.ios-card-body etc.) sits at z-index: 1 above this layer,
     * so text/icons are never passed through the distortion filter.
     */
    .glass-layer {
      position: absolute;
      inset: 0;
      border-radius: inherit;
      background: var(--card-bg);
      border: 1px solid var(--card-border);
      /* top-edge specular */
      box-shadow: inset 0 0.5px 0 var(--specular-top);
      backdrop-filter: blur(var(--card-blur)) saturate(var(--card-saturate));
      -webkit-backdrop-filter: blur(var(--card-blur)) saturate(var(--card-saturate));
      /* Liquid glass SVG filter (appearance-blur stdDeviation 1.1, within 0.9–1.5) */
      filter: url(#liquid-glass);
      z-index: 0;
      pointer-events: none;
    }

    /* Specular gradient — top-bright catch light fading to nothing */
    .glass-layer::after {
      content: '';
      position: absolute;
      inset: 0;
      border-radius: inherit;
      background: var(--specular-gradient);
      pointer-events: none;
    }

    /* All card content must sit above the glass layer */
    .ios-card-body {
      position: relative;
      z-index: 1;
      padding: 22px;
    }

    /* ── Profile widget — floats transparently on the wallpaper ── */
    .profile-widget {
      border-radius: 0;
      background: transparent;
      box-shadow: none;
      min-height: 360px;
      display: flex;
      flex-direction: column;
      justify-content: flex-end;
    }

    /* Gradient scrim darkens the lower portion for text legibility */
    .profile-widget::before {
      content: '';
      position: absolute;
      inset: 0;
      z-index: 0;
      border-radius: inherit;
      background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.00)  0%,
        rgba(0, 0, 0, 0.04) 45%,
        rgba(0, 0, 0, 0.55) 75%,
        rgba(0, 0, 0, 0.78) 100%
      );
      pointer-events: none;
    }

    .profile-content {
      position: relative;
      z-index: 1;
      padding: 20px 20px 0;
      display: flex;
      gap: 16px;
      align-items: flex-end;
    }

    .profile-avatar {
      width: 116px;
      height: 116px;
      border-radius: 30px;
      border: 2.5px solid rgba(255, 255, 255, 0.50);
      box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18), inset 0 0 0 0.5px rgba(255, 255, 255, 0.30);
      flex-shrink: 0;
      overflow: hidden;
      background: var(--fill);
    }

    .profile-avatar img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      object-position: center top;
      display: block;
    }

    .profile-info {
      min-width: 0;
      flex: 1;
    }

    .profile-name {
      font-size: 1.5rem;
      font-weight: 780;
      letter-spacing: -0.025em;
      line-height: 1.15;
      color: #ffffff;
      text-shadow: 0 1px 6px rgba(0, 0, 0, 0.40);
    }

    .profile-role {
      font-size: 0.9rem;
      font-weight: 600;
      color: rgba(255, 255, 255, 0.85);
      margin-top: 3px;
    }

    .profile-tagline {
      font-size: 0.86rem;
      font-weight: 450;
      color: rgba(255, 255, 255, 0.70);
      margin-top: 6px;
      line-height: 1.5;
    }

    .profile-links {
      position: relative;
      z-index: 1;
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin-top: 14px;
      padding: 0 20px 18px;
    }

    .profile-links a {
      width: 36px;
      height: 36px;
      border-radius: 12px;
      background: rgba(0, 0, 0, 0.30);
      border: 1px solid rgba(255, 255, 255, 0.22);
      box-shadow: inset 0 0.5px 0 rgba(255, 255, 255, 0.18);
      color: rgba(255, 255, 255, 0.80);
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 0.95rem;
      transition: background 0.15s, color 0.15s, transform 0.15s;
    }

    .profile-links a:hover {
      text-decoration: none;
      background: rgba(255, 255, 255, 0.20);
      color: #ffffff;
      transform: scale(1.06);
    }

    .profile-meta {
      position: relative;
      z-index: 1;
      display: flex;
      flex-wrap: wrap;
      gap: 6px;
      padding: 0 20px 16px;
    }

    .meta-pill {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      padding: 6px 12px;
      border-radius: 12px;
      background: rgba(0, 0, 0, 0.28);
      border: 1px solid rgba(255, 255, 255, 0.18);
      box-shadow: inset 0 0.5px 0 rgba(255, 255, 255, 0.14);
      color: rgba(255, 255, 255, 0.78);
      font-size: 0.82rem;
      font-weight: 550;
    }

    .meta-pill i {
      font-size: 0.72rem;
      color: rgba(255, 255, 255, 0.60);
    }

    /* ── Section header ── */
    .section-label {
      font-size: 0.70rem;
      font-weight: 700;
      color: var(--text-quaternary);
      text-transform: uppercase;
      letter-spacing: 0.07em;
      margin-bottom: 5px;
      text-shadow: 0 0.5px 2px rgba(0, 0, 0, 0.08);
    }

    .section-header {
      padding-bottom: 14px;
      border-bottom: 1px solid var(--separator);
      margin-bottom: 14px;
    }

    .section-title {
      font-size: 1.28rem;
      font-weight: 750;
      letter-spacing: -0.025em;
      color: var(--text);
      line-height: 1.2;
    }

    .section-subtitle {
      font-size: 0.84rem;
      color: var(--text-tertiary);
      margin-top: 2px;
    }

    /* ── Text content ── */
    .prose {
      color: var(--text-secondary);
      line-height: 1.72;
      font-weight: 450;
    }

    .prose + .prose {
      margin-top: 14px;
    }

    .prose strong {
      color: var(--text);
      font-weight: 650;
    }

    .prose em {
      color: var(--text-tertiary);
    }

    .prose a {
      font-weight: 550;
    }

    /* ── iOS-style list rows ── */
    .ios-row-group {
      display: grid;
      gap: 0;
    }

    .ios-row {
      padding: 14px 0;
      border-bottom: 1px solid var(--separator);
    }

    .ios-row:last-child {
      border-bottom: none;
    }

    .ios-row-title {
      font-size: 0.96rem;
      font-weight: 700;
      color: var(--text);
      line-height: 1.35;
    }

    .ios-row-subtitle {
      font-size: 0.86rem;
      font-weight: 500;
      color: var(--text-quaternary);
      margin-top: 3px;
    }

    .ios-row-meta {
      font-size: 0.86rem;
      font-weight: 450;
      color: var(--text-tertiary);
      margin-top: 5px;
      line-height: 1.58;
    }

    .ios-row-body {
      font-weight: 450;
      color: var(--text-secondary);
      margin-top: 8px;
      line-height: 1.68;
    }

    .ios-row-body strong {
      color: var(--text);
      font-weight: 650;
    }

    /* ── Inner card — liquid glass nesting ── */
    .ios-inner-card {
      margin-top: 10px;
      padding: 14px 16px;
      border-radius: 16px;
      background: var(--inner-card-bg);
      border: 1px solid var(--inner-card-border);
      box-shadow: inset 0 0.5px 0 var(--specular-top);
      backdrop-filter: blur(24px) saturate(160%);
      -webkit-backdrop-filter: blur(24px) saturate(160%);
    }

    /* ── Award badges ── */
    .award-badge {
      display: flex;
      gap: 8px;
      align-items: flex-start;
      margin-top: 8px;
      font-size: 0.86rem;
      font-weight: 500;
      color: var(--text-tertiary);
      line-height: 1.48;
    }

    .award-badge i {
      color: var(--gold);
      margin-top: 2px;
      flex-shrink: 0;
      font-size: 0.85rem;
    }

    /* ── Disclosure / details — quiet inline trigger, no box ── */
    details {
      margin-top: 10px;
      padding: 0;
      border: none;
      background: transparent;
      box-shadow: none;
      backdrop-filter: none;
      -webkit-backdrop-filter: none;
      border-radius: 0;
    }

    summary {
      cursor: pointer;
      list-style: none;
      display: inline-flex;
      align-items: center;
      gap: 5px;
      font-size: 0.76rem;
      font-weight: 500;
      color: var(--text-quaternary);
      padding: 2px 0;
      line-height: 1.2;
      text-underline-offset: 2px;
      text-decoration: underline;
      text-decoration-style: dotted;
      text-decoration-color: var(--separator-opaque);
    }

    summary::-webkit-details-marker { display: none; }
    summary i { font-size: 0.6rem; transition: transform 0.2s; }
    details[open] summary i { transform: rotate(90deg); }
    details[open] summary { margin-bottom: 10px; }

    .detail-content {
      font-size: 0.86rem;
      font-weight: 450;
      color: var(--text-tertiary);
      padding-bottom: 10px;
      line-height: 1.62;
    }

    .detail-content p { color: var(--text-tertiary); }
    .detail-content p + p { margin-top: 8px; }
    .detail-content strong { color: var(--text-secondary); font-weight: 650; }

    .detail-content ul {
      padding-left: 18px;
      display: grid;
      gap: 5px;
      margin-top: 6px;
    }

    .detail-content li { line-height: 1.5; }

    /* ── Skills — tag cloud ── */
    .skill-category {
      padding: 14px 0;
      border-bottom: 1px solid var(--separator);
    }

    .skill-category:first-child { padding-top: 0; }
    .skill-category:last-child { border-bottom: none; }

    .skill-category-label {
      font-size: 0.72rem;
      font-weight: 700;
      color: var(--text-quaternary);
      text-transform: uppercase;
      letter-spacing: 0.08em;
      margin-bottom: 10px;
    }

    .tag-cloud {
      display: flex;
      flex-wrap: wrap;
      gap: 7px;
    }

    .tag {
      display: inline-flex;
      align-items: center;
      padding: 6px 12px;
      border-radius: 999px;
      background: var(--tag-bg);
      color: var(--tag-text);
      font-size: 0.82rem;
      font-weight: 600;
    }

    /* ── Publications ── */
    .pub-list {
      list-style: none;
      padding: 0;
      display: grid;
      gap: 0;
    }

    .pub-item {
      padding: 12px 0;
      border-bottom: 1px solid var(--separator);
      font-weight: 450;
      line-height: 1.62;
      color: var(--text-secondary);
    }

    .pub-item:last-child { border-bottom: none; }

    .pub-item strong { color: var(--text); font-weight: 650; }
    .pub-item em { color: var(--text-tertiary); }
    .pub-item a {
      margin-left: 4px;
      font-size: 0.72rem;
      color: var(--accent);
      opacity: 0.7;
    }
    .pub-item a:hover { opacity: 1; }

    /* ── Projects — row list matching other sections ── */
    .project-grid {
      display: grid;
      gap: 0;
    }

    .project-cell {
      padding: 14px 0;
      border-bottom: 1px solid var(--separator);
      background: transparent;
      border-radius: 0;
      box-shadow: none;
      backdrop-filter: none;
      -webkit-backdrop-filter: none;
    }

    .project-cell:last-child {
      border-bottom: none;
    }

    .project-cell-title {
      font-size: 0.96rem;
      font-weight: 700;
      color: var(--text);
      margin-bottom: 5px;
    }

    .project-cell-title a {
      color: var(--accent);
    }

    .project-cell p {
      font-weight: 450;
      color: var(--text-secondary);
      line-height: 1.68;
    }

    .oss-links {
      margin-top: 12px;
      font-size: 0.8rem;
      color: var(--text-tertiary);
    }

    .oss-links a {
      font-weight: 500;
    }

    .scholar-link {
      margin-top: 10px;
      font-size: 0.82rem;
      color: var(--text-tertiary);
    }

    .scholar-link i {
      color: var(--accent);
      margin-right: 4px;
    }

    /* ── Venue badges ── */
    .venue-badge {
      display: inline-block;
      font-size: 0.68rem;
      font-weight: 700;
      letter-spacing: 0.03em;
      padding: 2px 7px;
      border-radius: 6px;
      margin-right: 6px;
      margin-bottom: 4px;
      vertical-align: middle;
      line-height: 1.7;
      white-space: nowrap;
    }

    .venue-acl    { background: rgba(0, 96, 204, 0.12);   color: #004faa; }
    .venue-emnlp  { background: rgba(98, 60, 234, 0.11);  color: #5330b8; }
    .venue-coling { background: rgba(0, 140, 130, 0.11);  color: #00706a; }
    .venue-lrec   { background: rgba(210, 100, 0, 0.11);  color: #b05500; }
    .venue-icon   { background: rgba(120, 120, 128, 0.11);color: #555560; }
    .venue-arxiv  { background: rgba(180, 28, 28, 0.11);  color: #9c1c1c; }

    [data-theme="dark"] .venue-acl    { background: rgba(10, 132, 255, 0.18);  color: #5ac8fa; }
    [data-theme="dark"] .venue-emnlp  { background: rgba(94, 92, 230, 0.20);   color: #bf8fff; }
    [data-theme="dark"] .venue-coling { background: rgba(0, 209, 193, 0.17);   color: #5de6de; }
    [data-theme="dark"] .venue-lrec   { background: rgba(255, 159, 10, 0.18);  color: #ffc244; }
    [data-theme="dark"] .venue-icon   { background: rgba(142, 142, 147, 0.18); color: #aeaeb2; }
    [data-theme="dark"] .venue-arxiv  { background: rgba(255, 69, 58, 0.18);   color: #ff6961; }

    @media (prefers-color-scheme: dark) {
      :root:not([data-theme="light"]) .venue-acl    { background: rgba(10, 132, 255, 0.18);  color: #5ac8fa; }
      :root:not([data-theme="light"]) .venue-emnlp  { background: rgba(94, 92, 230, 0.20);   color: #bf8fff; }
      :root:not([data-theme="light"]) .venue-coling { background: rgba(0, 209, 193, 0.17);   color: #5de6de; }
      :root:not([data-theme="light"]) .venue-lrec   { background: rgba(255, 159, 10, 0.18);  color: #ffc244; }
      :root:not([data-theme="light"]) .venue-icon   { background: rgba(142, 142, 147, 0.18); color: #aeaeb2; }
      :root:not([data-theme="light"]) .venue-arxiv  { background: rgba(255, 69, 58, 0.18);   color: #ff6961; }
    }

    /* ── Skill tag category color tints ── */
    .tag-nlp {
      background: rgba(0, 96, 204, 0.10);
      color: #0050b3;
    }

    .tag-infra {
      background: rgba(88, 50, 210, 0.10);
      color: #4d2db0;
    }

    .tag-frameworks {
      background: rgba(28, 150, 55, 0.10);
      color: #166c2c;
    }

    [data-theme="dark"] .tag-nlp         { background: rgba(10, 132, 255, 0.16); color: #5ac8fa; }
    [data-theme="dark"] .tag-infra       { background: rgba(94, 92, 230, 0.20);  color: #bf8fff; }
    [data-theme="dark"] .tag-frameworks  { background: rgba(48, 209, 88, 0.16);  color: #30d158; }

    @media (prefers-color-scheme: dark) {
      :root:not([data-theme="light"]) .tag-nlp        { background: rgba(10, 132, 255, 0.16); color: #5ac8fa; }
      :root:not([data-theme="light"]) .tag-infra      { background: rgba(94, 92, 230, 0.20);  color: #bf8fff; }
      :root:not([data-theme="light"]) .tag-frameworks { background: rgba(48, 209, 88, 0.16);  color: #30d158; }
    }

    /* ── Clear mode — content floats on wallpaper without glass shells ── */
    [data-style="clear"] .ios-card:not(.profile-widget) {
      background: transparent;
      box-shadow: none;
    }
    [data-style="clear"] .ios-card:not(.profile-widget) .glass-layer {
      display: none;
    }
    /* background_bold.jpg is always dark — force light text in clear mode
       regardless of theme, since tinted cards are what create a light surface in light mode */
    [data-style="clear"] .ios-card:not(.profile-widget) {
      --text: #ffffff;
      --text-secondary: rgba(255, 255, 255, 0.92);
      --text-tertiary: rgba(255, 255, 255, 0.72);
      --text-quaternary: rgba(255, 255, 255, 0.50);
      --separator: rgba(255, 255, 255, 0.15);
      --accent: #5ac8fa;
      --tag-bg: rgba(255, 255, 255, 0.12);
      --tag-text: rgba(255, 255, 255, 0.78);
    }
    /* Subtle scrim behind card content for legibility over busy wallpaper */
    [data-style="clear"] .ios-card:not(.profile-widget) .ios-card-body {
      background: rgba(0, 0, 0, 0.32);
      backdrop-filter: blur(5px);
      -webkit-backdrop-filter: blur(5px);
      border-radius: 18px;
      padding-left: 20px;
      padding-right: 20px;
    }
    /* Light mode: lighter scrim — wallpaper bleeds through more */
    [data-theme="light"][data-style="clear"] .ios-card:not(.profile-widget) .ios-card-body {
      background: rgba(0, 0, 0, 0.18);
    }
    @media (prefers-color-scheme: light) {
      :root:not([data-theme="dark"])[data-style="clear"] .ios-card:not(.profile-widget) .ios-card-body {
        background: rgba(0, 0, 0, 0.18);
      }
    }

    /* ── Footer ── */
    .footer-note {
      text-align: center;
      font-size: 0.78rem;
      color: var(--text-quaternary);
      padding: 12px 0 8px;
    }

    /* ── Responsive ── */
    @media (max-width: 720px) {
      .ios-stack {
        padding: 16px 10px 36px;
        gap: 12px;
      }

      .profile-widget {
        min-height: 300px;
      }

      .profile-content {
        padding: 16px 16px 0;
      }

      .profile-avatar {
        width: 80px;
        height: 80px;
        border-radius: 22px;
      }


      .profile-name {
        font-size: 1.25rem;
      }

      .profile-links {
        padding: 0 16px 14px;
      }

      .profile-meta {
        padding: 0 16px 14px;
      }

      .ios-card-body {
        padding: 16px;
      }

      .section-title {
        font-size: 1.1rem;
      }

    }

    @media (max-width: 480px) {
      .controls {
        top: auto;
        bottom: 10px;
        right: 10px;
      }

      .ios-card {
        border-radius: 16px;
      }

      .profile-widget {
        border-radius: 0;
      }

      .profile-name {
        font-size: 1.15rem;
      }

      .profile-role {
        font-size: 0.82rem;
      }
    }
