:root {
  color-scheme: dark;
  --bg: #080A0E;
  --panel: #0D1016;
  --panel-2: #11151D;
  --line: #222833;
  --text: #F0F2F8;
  --muted: #929BAC;
  --accent: #B5A0FF;
  --accent-strong: #9476FF;
  --radius: 16px;
}
* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body { margin: 0; background: var(--bg); color: var(--text); font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR", sans-serif; font-size: 14px; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.app-shell { min-height: 100vh; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: 246px; padding: 28px 17px 18px; display: flex; flex-direction: column; background: #0A0C11; border-right: 1px solid var(--line); z-index: 5; }
.brand { display: flex; align-items: center; gap: 11px; margin: 0 10px 42px; text-decoration: none; color: var(--text); }
.brand-mark { display: grid; place-items: center; width: 39px; height: 39px; border-radius: 12px; background: linear-gradient(145deg, #D0C2FF, #8C6EFF); color: #151023; font-weight: 900; font-size: 20px; box-shadow: 0 5px 22px #9c83ff25; }
.brand strong { display: block; font-size: 17px; letter-spacing: -.5px; }
.brand small { display: block; margin-top: 3px; font-size: 9px; letter-spacing: 1.8px; color: var(--muted); }
.side-link { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 43px; padding: 0 12px; border: 0; border-radius: 10px; background: transparent; color: #A9B0BF; text-align: left; }
.side-link > span:first-child { width: 18px; font-size: 18px; text-align: center; }
.side-link:hover, .side-link.active { background: #191626; color: #D5C9FF; }
.side-count { margin-left: auto; font-size: 11px; color: var(--muted); }
.sidebar-label { margin: 30px 12px 12px; color: #697184; font-size: 10px; font-weight: 700; letter-spacing: 1.4px; text-transform: uppercase; }
.category-nav { display: grid; gap: 4px; }
.category-nav .side-link { min-height: 39px; }
.category-dot { display: inline-block; width: 7px; height: 7px; margin: 0 5px 1px 5px; border-radius: 50%; background: #A994FF; }
.sidebar-bottom { margin-top: auto; }
.sidebar-note { margin: 17px 12px 0; padding-top: 17px; border-top: 1px solid var(--line); color: #626B7C; font-size: 12px; line-height: 1.8; }
.main { min-height: 100vh; margin-left: 246px; padding: 0 46px; max-width: 1800px; }
.topbar { display: flex; align-items: center; justify-content: space-between; height: 78px; border-bottom: 1px solid #1A1F29; }
.source-status { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #C3A8FF; box-shadow: 0 0 12px #B5A0FF55; }
.source-status.connected .status-dot { background: #68D6A3; box-shadow: 0 0 12px #68D6A355; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.icon-button { width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 11px; color: #C4CAD6; background: var(--panel); font-size: 22px; }
.icon-button:hover { border-color: #66558F; color: var(--accent); }
.primary-button, .secondary-button { min-height: 39px; padding: 0 15px; border-radius: 10px; font-weight: 650; transition: .18s ease; }
.primary-button { border: 1px solid #B6A4FF; background: #B5A0FF; color: #171124; }
.primary-button:hover { background: #C9BCFF; transform: translateY(-1px); }
.secondary-button { border: 1px solid var(--line); background: #151922; color: #D1D6E0; }
.secondary-button:hover { border-color: #66558F; }
.mobile-brand { display: none; }
.welcome { position: relative; display: flex; align-items: center; justify-content: space-between; min-height: 210px; padding: 30px 0 27px; overflow: hidden; }
.eyebrow { color: #A995F7; font-size: 10px; font-weight: 750; letter-spacing: 2px; }
.welcome h1 { margin: 12px 0 10px; font-size: clamp(30px, 3.3vw, 43px); line-height: 1.1; letter-spacing: -1.9px; }
.welcome h1 span { color: var(--accent); }
.welcome p { margin: 0; color: var(--muted); font-size: 14px; }
.welcome-orb { position: absolute; right: 8%; top: -70px; display: grid; place-items: center; width: 270px; height: 270px; border: 1px solid #a995f719; border-radius: 50%; background: radial-gradient(circle at 38% 35%, #b5a0ff18, #b5a0ff02 58%, transparent 70%); color: #B5A0FF18; font-size: 105px; font-weight: 900; pointer-events: none; }
.welcome-orb:before, .welcome-orb:after { position: absolute; content: ""; border: 1px solid #a995f715; border-radius: 50%; }
.welcome-orb:before { inset: 25px; } .welcome-orb:after { inset: 52px; }
.welcome-orb span { z-index: 1; }
.toolbar { display: flex; align-items: center; gap: 12px; margin: 7px 0 34px; }
.search-box { display: flex; align-items: center; gap: 11px; flex: 1; min-width: 0; height: 46px; padding: 0 14px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; color: #929BAC; }
.search-box > span { font-size: 24px; line-height: 1; }
.search-box input { width: 100%; min-width: 0; padding: 0; border: 0; outline: 0; background: transparent; color: var(--text); }
.search-box input::placeholder { color: #687184; }
kbd { flex-shrink: 0; padding: 3px 6px; border: 1px solid #303746; border-radius: 5px; color: #747D8F; font-size: 10px; }
select { height: 46px; padding: 0 35px 0 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); color: #BFC6D3; }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.section-heading h2 { margin: 0 0 6px; font-size: 19px; letter-spacing: -.4px; }
.section-heading p { margin: 0; color: #737D8E; font-size: 12px; }
.view-toggle { display: flex; padding: 3px; gap: 3px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); }
.view-button { width: 31px; height: 29px; border: 0; border-radius: 6px; background: transparent; color: #7F899A; font-size: 17px; }
.view-button.selected { background: #282238; color: #CDBFFF; }
.website-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 17px; }
.site-card { min-width: 0; overflow: hidden; border: 1px solid #222833; border-radius: 14px; background: #0D1016; transition: border-color .2s, transform .2s, background .2s; }
.site-card:hover { transform: translateY(-3px); border-color: #5C4D83; background: #10131B; }
.site-thumb { position: relative; display: grid; place-items: center; width: 100%; aspect-ratio: 1.9 / 1; overflow: hidden; border: 0; border-bottom: 1px solid #222833; background: radial-gradient(circle at 50% 0%, #B5A0FF19, transparent 65%), #11151D; color: #C5B8FF; cursor: pointer; }
.site-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.thumb-letter { display: grid; place-items: center; width: 53px; height: 53px; border: 1px solid #B5A0FF33; border-radius: 17px; background: #B5A0FF0D; color: #C7B9FF; font-size: 25px; font-weight: 800; }
.site-card-body { padding: 15px 15px 14px; }
.card-title-row { display: flex; align-items: flex-start; gap: 8px; }
.site-title { flex: 1; min-width: 0; margin: 0; overflow: hidden; color: #F0F2F8; font-size: 14px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.site-category { flex-shrink: 0; max-width: 42%; overflow: hidden; padding: 4px 7px; border-radius: 5px; background: #211D30; color: #BDAEFF; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.site-description { display: -webkit-box; min-height: 36px; margin: 10px 0 13px; overflow: hidden; color: #8992A3; font-size: 12px; line-height: 1.55; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 11px; border-top: 1px solid #202530; }
.site-domain { min-width: 0; overflow: hidden; color: #687386; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.open-site { display: inline-flex; align-items: center; gap: 5px; flex-shrink: 0; padding: 5px 8px; border: 1px solid #39304F; border-radius: 7px; background: #1B1726; color: #C9BCFF; font-size: 11px; text-decoration: none; }
.open-site:hover { background: #2B2240; }
.site-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px; }
.site-tag { padding: 3px 6px; border-radius: 5px; background: #171B24; color: #8D97A9; font-size: 10px; }
.website-grid.list-layout { grid-template-columns: 1fr; gap: 9px; }
.list-layout .site-card { display: grid; grid-template-columns: 150px minmax(0, 1fr); }
.list-layout .site-thumb { height: 100%; min-height: 125px; aspect-ratio: auto; border-right: 1px solid #222833; border-bottom: 0; }
.list-layout .site-card-body { padding: 13px 16px; }
.list-layout .site-description { min-height: auto; margin: 7px 0 9px; }
.list-layout .site-tags { margin-top: 7px; }
.empty-state { padding: 60px 15px; text-align: center; border: 1px dashed #2A3040; border-radius: 16px; background: #0C0F15; }
.empty-state.hidden { display: none; }
.empty-icon { display: grid; place-items: center; width: 55px; height: 55px; margin: 0 auto 16px; border-radius: 17px; background: #1C172A; color: #C4B5FF; font-size: 30px; }
.empty-state h3 { margin: 0 0 8px; font-size: 17px; }
.empty-state p { margin: 0 0 20px; color: var(--muted); }
.footer { display: flex; justify-content: space-between; gap: 10px; margin-top: 65px; padding: 20px 0 24px; border-top: 1px solid #1A1F29; color: #596274; font-size: 10px; }
.footer span:first-child { letter-spacing: 1.8px; }
.close-button { display: grid; place-items: center; flex-shrink: 0; width: 34px; height: 34px; border: 1px solid #303747; border-radius: 9px; background: #151922; color: #AEB5C4; font-size: 24px; line-height: 1; }
.close-button:hover { color: white; border-color: #70608F; }
.reader-dialog { width: min(1400px, 96vw); height: min(900px, 92vh); max-width: none; max-height: none; padding: 0; overflow: hidden; border: 1px solid #303747; border-radius: 15px; background: #0D1016; color: var(--text); }
.reader-dialog::backdrop { background: #030408D9; backdrop-filter: blur(4px); }
.reader-topbar { display: flex; align-items: center; justify-content: space-between; gap: 15px; min-height: 67px; padding: 10px 16px; border-bottom: 1px solid #282E3A; }
.reader-title-wrap { display: flex; align-items: center; gap: 10px; min-width: 0; }
.reader-favicon { display: grid; place-items: center; width: 35px; height: 35px; flex-shrink: 0; border-radius: 10px; background: #211C30; color: #C8BAFF; font-weight: 800; }
.reader-title-wrap strong, .reader-title-wrap small { display: block; max-width: 55vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reader-title-wrap strong { font-size: 13px; }
.reader-title-wrap small { margin-top: 4px; color: #7D8798; font-size: 10px; }
.reader-actions { display: flex; align-items: center; gap: 8px; }
.reader-notice { display: flex; align-items: center; gap: 6px; min-height: 35px; padding: 6px 15px; background: #171522; color: #AFA6D1; font-size: 11px; }
.reader-notice b { color: #D4C9FF; }
#readerFrame { display: block; width: 100%; height: calc(100% - 102px); border: 0; background: white; }
.toast { position: fixed; right: 24px; bottom: 24px; z-index: 20; max-width: min(420px, calc(100vw - 32px)); padding: 12px 16px; border: 1px solid #39334A; border-radius: 10px; background: #1B1725; color: #E2DAFF; box-shadow: 0 8px 30px #0006; opacity: 0; transform: translateY(10px); pointer-events: none; transition: .2s; }
.toast.show { opacity: 1; transform: translateY(0); }
@media (max-width: 1200px) { .main { padding: 0 30px; } .website-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .welcome-orb { right: 0; } }
@media (max-width: 850px) { .sidebar { width: 205px; padding-inline: 12px; } .main { margin-left: 205px; padding: 0 22px; } .website-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .welcome-orb { right: -80px; opacity: .6; } }
@media (max-width: 640px) {
  .sidebar { display: none; } .main { margin-left: 0; padding: 0 16px; }
  .topbar { height: 65px; } .mobile-brand { display: flex; align-items: center; gap: 9px; } .mobile-brand .brand-mark { width: 31px; height: 31px; border-radius: 9px; font-size: 16px; } .mobile-brand strong { font-size: 15px; }
  .source-status { display: none; } .top-actions { margin-left: auto; } .primary-button, .secondary-button { min-height: 36px; padding: 0 11px; font-size: 12px; }
  .welcome { min-height: 170px; } .welcome h1 { font-size: 34px; } .welcome p { max-width: 260px; font-size: 12px; line-height: 1.6; } .welcome-orb { right: -155px; top: -35px; width: 230px; height: 230px; }
  .toolbar { align-items: stretch; flex-direction: column; margin-bottom: 27px; } .search-box { flex: auto; } .toolbar select { width: 100%; height: 39px; }
  .website-grid { grid-template-columns: 1fr 1fr; gap: 10px; } .site-card { border-radius: 11px; } .site-card-body { padding: 10px; } .site-title { font-size: 12px; } .site-category { display: none; } .site-description { min-height: 34px; font-size: 11px; } .card-bottom { align-items: flex-start; flex-direction: column; } .open-site { align-self: flex-start; } .site-tags { display: none; }
  .list-layout .site-card { grid-template-columns: 94px minmax(0, 1fr); } .list-layout .site-thumb { min-height: 100%; } .list-layout .site-card-body { padding: 10px; }
  .section-heading h2 { font-size: 17px; } .section-heading p { font-size: 11px; } .footer { margin-top: 40px; flex-direction: column; }
  .reader-dialog { width: 100vw; height: 100dvh; border-radius: 0; } .reader-topbar { align-items: flex-start; } .reader-actions { gap: 5px; } .reader-actions .secondary-button { max-width: 110px; line-height: 1.3; } .reader-title-wrap strong, .reader-title-wrap small { max-width: 33vw; }
}
@media (max-width: 370px) { .website-grid { grid-template-columns: 1fr; } .site-category { display: inline-block; } .site-description { min-height: auto; } }
