:root {
      --bg: #0f1420;
      --panel: #141f33;
      --panel2: #15243a;
      --text: #f2f1eb;
      --muted: #c7c1af;
      --accent: #bee1ff;
      --border: #334663;
    }
    * { box-sizing: border-box; }
    body {
      margin: 0;
      min-height: 100vh;
      padding: 24px;
      font-family: "Trebuchet MS", "Segoe UI", sans-serif;
      color: var(--text);
      background:
        radial-gradient(1000px 500px at 20% -10%, #2e405f 0%, transparent 60%),
        radial-gradient(900px 480px at 90% 0%, #2a2b44 0%, transparent 55%),
        linear-gradient(170deg, #1a2333 0%, var(--bg) 56%, #0b111a 100%);
    }
    main {
      width: min(980px, 100%);
      margin: 0 auto;
      border: 1px solid var(--border);
      border-radius: 14px;
      padding: 24px;
      background: linear-gradient(180deg, rgba(17, 26, 43, 0.92), rgba(15, 22, 35, 0.97));
      box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
    }
    h1 { margin: 0 0 8px; color: #f0d494; }
    p { margin: 0 0 14px; color: var(--muted); }
    .hero {
      display: grid;
      gap: 14px;
      margin-bottom: 20px;
      padding: 0 0 18px;
      border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }
    .profile-cover {
      position: relative;
      min-height: 190px;
      margin: -24px -24px 0;
      background:
        linear-gradient(180deg, rgba(8, 12, 18, 0.14), rgba(8, 12, 18, 0.58)),
        url('/qwertyhouse-assets/img/qwertyhouse-header-site.png') center / cover no-repeat;
      border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }
    .profile-avatar {
      position: absolute;
      left: 20px;
      bottom: -34px;
      width: 96px;
      height: 96px;
      border-radius: 999px;
      object-fit: cover;
      border: 4px solid #0f1420;
      box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
      background: #15243a;
    }
    .hero-body {
      padding-top: 42px;
    }
    .hero-copy {
      max-width: 70ch;
    }
    .profile-handle {
      color: #9fb4d6;
      font-size: 0.95rem;
      margin: 6px 0 12px;
    }
    .hero-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
    }
    .hero-actions .btn {
      margin: 0;
    }
    .feed-meta {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 12px;
    }
    .profile-stats {
      display: flex;
      flex-wrap: wrap;
      gap: 14px;
      margin: 14px 0 0;
      padding-top: 14px;
      border-top: 1px solid rgba(255, 255, 255, 0.08);
    }
    .profile-stat {
      display: inline-flex;
      gap: 6px;
      align-items: center;
      color: #bfd0ea;
      font-size: 0.9rem;
    }
    .profile-stat strong {
      color: #f7efe0;
    }
    .profile-tabs {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin-top: 16px;
    }
    .profile-tab {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 10px 14px;
      border-radius: 999px;
      border: 1px solid var(--border);
      background: rgba(16, 24, 38, 0.65);
      color: #d7e9ff;
      text-decoration: none;
      font-size: 0.88rem;
      font-weight: 600;
    }
    .profile-tab:hover, .profile-tab:focus-visible {
      background: #20385b;
      border-color: #6b90c2;
    }
    .meta-card {
      border: 1px solid var(--border);
      border-radius: 10px;
      padding: 12px;
      background: rgba(255, 255, 255, 0.03);
    }
    .meta-card strong {
      display: block;
      margin-bottom: 6px;
      color: #f7efe0;
      font-size: 0.95rem;
    }
    .meta-card span {
      color: #bfd0ea;
      font-size: 0.88rem;
      line-height: 1.45;
    }
    #feeds {
      display: grid;
      gap: 18px;
    }
    .source { margin-top: 16px; }
    .source {
      border: 1px solid rgba(255, 255, 255, 0.07);
      border-radius: 14px;
      padding: 18px;
      background: rgba(255, 255, 255, 0.02);
    }
    .source h2 { margin: 0 0 8px; font-size: 1.2rem; color: #f7efe0; }
    .grid { display: grid; gap: 10px; }
    .card {
      border: 1px solid var(--border);
      border-radius: 10px;
      padding: 14px;
      background: var(--panel2);
      white-space: pre-wrap;
      line-height: 1.4;
    }
    .meta { color: #bfd0ea; font-size: .9rem; margin-bottom: 8px; }
    .post-image {
      margin-top: 10px;
      width: 100%;
      max-width: 420px;
      border-radius: 8px;
      border: 1px solid #446086;
      display: block;
    }
    .links { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
    .btn {
      display: inline-block;
      color: #d7e9ff;
      text-decoration: none;
      border: 1px solid #446086;
      border-radius: 10px;
      padding: 9px 12px;
      background: #15243a;
    }
    .btn:hover, .btn:focus-visible { text-decoration: underline; border-color: #6b90c2; background: #20385b; }

    .loading-card {
      border: 1px solid var(--border);
      border-radius: 10px;
      padding: 16px;
      background: linear-gradient(90deg, rgba(21, 36, 58, 0.9), rgba(41, 62, 92, 0.9), rgba(21, 36, 58, 0.9));
      background-size: 220% 100%;
      animation: shimmer 1.2s linear infinite;
      color: #d7e9ff;
    }

    @keyframes shimmer {
      0% { background-position: 100% 0; }
      100% { background-position: -100% 0; }
    }

    @media (max-width: 780px) {
      .feed-meta {
        grid-template-columns: 1fr;
      }
      .profile-cover {
        min-height: 150px;
      }
      .profile-avatar {
        width: 82px;
        height: 82px;
        bottom: -22px;
      }
      .hero-body {
        padding-top: 28px;
      }
    }

.post-link-row { margin-top: 8px; }
