@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
  --ink: #14213d;
  --muted: #72809b;
  --line: #e5eaf5;
  --surface: #ffffff;
  --shell: #f5f7fc;
  --accent: #5968ed;
  --accent-dark: #4352d5;
  --accent-soft: #eef0ff;
  --mint: #d8f4ec;
  --peach: #ffe4d2;
  --yellow: #fff0ba;
  --shadow: 0 24px 80px rgba(47, 61, 111, 0.11);
  --radius-lg: 24px;
  --radius-md: 16px;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--shell); }
body { margin: 0; min-width: 320px; color: var(--ink); background: var(--shell); font-family: 'Manrope', sans-serif; }
button, input { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, a:focus-visible { outline: 3px solid rgba(89,104,237,.3); outline-offset: 3px; }

.app-shell { min-height: 100vh; padding: 30px 42px 20px; display: flex; flex-direction: column; gap: 22px; }
.topbar { display: flex; justify-content: space-between; align-items: center; max-width: 1440px; width: 100%; margin: 0 auto; }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: white; background: linear-gradient(135deg, #7783ff 0%, #4453d7 100%); box-shadow: 0 8px 18px rgba(71, 85, 220, .25); font-size: 21px; font-weight: 800; letter-spacing: -2px; }
.brand-copy { display: flex; flex-direction: column; line-height: 1; gap: 4px; }
.brand-copy strong { font-size: 17px; letter-spacing: -.5px; }
.brand-copy small { color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: 1.3px; font-family: 'DM Mono', monospace; }
.topbar-actions { display: flex; align-items: center; gap: 9px; }
.icon-button, .toolbar-button, .new-tab, .close-button { border: 0; background: transparent; color: var(--muted); }
.icon-button { width: 37px; height: 37px; border-radius: 50%; display: grid; place-items: center; transition: .2s ease; }
.icon-button.soft { background: #ebeff8; }
.icon-button:hover, .toolbar-button:hover, .new-tab:hover { color: var(--accent); background: var(--accent-soft); }
.icon { font-size: 19px; line-height: 1; }
.avatar { width: 37px; height: 37px; display: grid; place-items: center; border-radius: 50%; color: #3946b6; background: var(--yellow); font-weight: 800; font-size: 13px; }

.browser-window { max-width: 1440px; width: 100%; min-height: 680px; margin: 0 auto; flex: 1; overflow: hidden; background: var(--surface); border: 1px solid rgba(222, 228, 242, .8); border-radius: 24px; box-shadow: var(--shadow); }
.tab-strip { min-height: 57px; padding: 11px 16px 0; display: flex; align-items: flex-end; gap: 9px; background: #eef1f8; border-bottom: 1px solid var(--line); }
.tabs { display: flex; gap: 7px; overflow: auto hidden; max-width: calc(100% - 40px); scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { min-width: 180px; max-width: 245px; height: 45px; padding: 0 12px 0 15px; display: flex; align-items: center; gap: 9px; border: 1px solid transparent; border-radius: 12px 12px 0 0; color: var(--muted); background: transparent; font-size: 12px; }
.tab.active { color: var(--ink); background: white; border-color: var(--line); border-bottom-color: white; }
.tab-favicon { width: 18px; height: 18px; flex: 0 0 18px; display: grid; place-items: center; border-radius: 6px; color: white; background: var(--accent); font-size: 10px; font-weight: 800; }
.tab-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; padding: 0; border: 0; color: inherit; background: transparent; text-align: left; font-size: inherit; }
.tab-close { border: 0; padding: 2px 3px; color: inherit; background: transparent; font-size: 16px; line-height: 1; opacity: .65; }
.tab-close:hover { color: #ec6676; opacity: 1; }
.new-tab { width: 34px; height: 34px; margin: 0 0 5px; border-radius: 10px; font-size: 22px; line-height: 1; }

.browser-toolbar { min-height: 67px; padding: 12px 20px; display: flex; align-items: center; gap: 15px; border-bottom: 1px solid var(--line); background: white; }
.navigation-actions { display: flex; gap: 2px; }
.toolbar-button { width: 32px; height: 32px; border-radius: 9px; font-size: 19px; line-height: 1; transition: .2s ease; }
.menu-button { font-weight: 800; letter-spacing: 1px; font-size: 15px; }
.address-form { min-width: 0; height: 40px; flex: 1; display: flex; align-items: center; gap: 9px; padding: 0 12px; border: 1px solid #e2e7f3; border-radius: 12px; color: var(--muted); background: #f7f8fc; transition: .2s ease; }
.address-form:focus-within { border-color: #abb4ff; box-shadow: 0 0 0 4px rgba(89, 104, 237, .08); background: white; }
.address-lock { font-size: 19px; color: #62a990; transform: rotate(-25deg); }
.address-form input { min-width: 0; width: 100%; padding: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 12px; }
.address-form input::placeholder { color: #a0abc0; }
.address-star { padding: 0 2px; border: 0; color: #9aa6be; background: transparent; font-size: 21px; line-height: 1; }
.address-star.is-favorite { color: #f3af32; }

.browser-content { min-height: 555px; background: linear-gradient(180deg, #fbfcff 0%, #f8faff 100%); }
.home-page { max-width: 1100px; margin: 0 auto; padding: 67px 44px 50px; }
.hero-line { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.eyebrow { display: block; margin-bottom: 14px; color: var(--accent); font-family: 'DM Mono', monospace; font-size: 10px; text-transform: uppercase; letter-spacing: 1.7px; }
.hero-title { max-width: 620px; margin: 0; font-size: clamp(37px, 5vw, 65px); line-height: .99; letter-spacing: -3.7px; font-weight: 800; }
.hero-title em { color: var(--accent); font-style: normal; }
.hero-description { max-width: 470px; margin: 18px 0 0; color: var(--muted); line-height: 1.65; font-size: 14px; }
.time-block { padding: 13px 16px; border-left: 2px solid var(--accent); text-align: right; }
.time-block span { display: block; color: var(--muted); font-family: 'DM Mono', monospace; font-size: 9px; text-transform: uppercase; letter-spacing: 1.5px; }
.time-block strong { display: block; margin-top: 4px; font-size: 20px; letter-spacing: -1px; }
.search-hero { max-width: 760px; margin: 45px auto 53px; }
.search-box { height: 66px; padding: 0 9px 0 21px; display: flex; align-items: center; gap: 13px; background: white; border: 1px solid #dfe4f1; border-radius: 17px; box-shadow: 0 15px 30px rgba(54, 69, 125, .08); }
.search-icon { font-size: 20px; color: var(--accent); }
.search-box input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 14px; }
.search-box input::placeholder { color: #9aa6bb; }
.search-submit { height: 48px; padding: 0 20px; border: 0; border-radius: 12px; color: white; background: var(--ink); font-size: 12px; font-weight: 700; transition: .2s ease; }
.search-submit:hover { background: var(--accent); transform: translateY(-1px); }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.section-heading h2 { margin: 0; font-size: 13px; letter-spacing: -.2px; }
.section-heading button, .text-button { border: 0; color: var(--accent); background: transparent; font-size: 11px; font-weight: 700; }
.quick-links { display: grid; grid-template-columns: repeat(4, 1fr); gap: 11px; }
.quick-link { min-height: 90px; padding: 17px; display: flex; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: 15px; color: var(--ink); background: white; text-align: left; transition: .2s ease; }
.quick-link:hover { border-color: #c6ccfc; box-shadow: 0 10px 25px rgba(54, 69, 125, .07); transform: translateY(-2px); }
.quick-icon { width: 37px; height: 37px; display: grid; place-items: center; flex: 0 0 37px; border-radius: 11px; color: #4a4e74; background: var(--peach); font-weight: 800; font-size: 14px; }
.quick-link:nth-child(2) .quick-icon { background: var(--mint); color: #2d806d; }
.quick-link:nth-child(3) .quick-icon { background: var(--accent-soft); color: var(--accent); }
.quick-link:nth-child(4) .quick-icon { background: var(--yellow); color: #a07809; }
.quick-link strong { display: block; font-size: 12px; }
.quick-link small { display: block; margin-top: 4px; color: var(--muted); font-size: 10px; }
.bottom-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; margin-top: 47px; }
.list-card { min-width: 0; }
.activity-row { min-height: 48px; display: flex; align-items: center; gap: 11px; border-top: 1px solid var(--line); }
.activity-row:last-child { border-bottom: 1px solid var(--line); }
.activity-dot { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 8px; color: #4a5bbf; background: var(--accent-soft); font-size: 11px; }
.activity-copy { min-width: 0; flex: 1; }
.activity-copy strong, .activity-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.activity-copy strong { font-size: 11px; }
.activity-copy span { margin-top: 2px; color: var(--muted); font-size: 9px; }
.empty-state { padding: 19px 0; color: var(--muted); font-size: 11px; }

.result-page { max-width: 1000px; margin: 0 auto; padding: 48px 45px 56px; }
.result-header { padding-bottom: 26px; border-bottom: 1px solid var(--line); }
.result-header h1 { margin: 0; font-size: 33px; letter-spacing: -1.5px; }
.result-header p { margin: 10px 0 0; color: var(--muted); font-size: 12px; }
.result-card { padding: 22px 0; border-bottom: 1px solid var(--line); }
.result-card .result-url { color: #508b7c; font-family: 'DM Mono', monospace; font-size: 10px; }
.result-card h3 { margin: 7px 0; color: var(--accent-dark); font-size: 17px; }
.result-card p { max-width: 700px; margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.result-card button { margin-top: 14px; padding: 8px 12px; border: 0; border-radius: 8px; color: var(--accent); background: var(--accent-soft); font-size: 10px; font-weight: 700; }

.overlay-message { max-width: 620px; margin: 80px auto; padding: 35px; text-align: center; border: 1px solid var(--line); border-radius: 19px; background: white; }
.overlay-message .message-icon { font-size: 30px; }
.overlay-message h2 { margin: 15px 0 8px; font-size: 22px; }
.overlay-message p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.overlay-message button { margin-top: 20px; padding: 11px 17px; border: 0; border-radius: 10px; color: white; background: var(--accent); font-size: 11px; font-weight: 700; }

.app-footer { max-width: 1440px; width: 100%; margin: 0 auto; display: flex; justify-content: space-between; color: #99a4b8; font-size: 10px; }
.creator-credit strong { color: var(--accent); font-weight: 700; }
.side-drawer { position: fixed; z-index: 20; top: 0; right: 0; bottom: 0; width: min(390px, 92vw); padding: 30px 25px; overflow-y: auto; background: white; box-shadow: -12px 0 45px rgba(29, 42, 87, .13); transform: translateX(100%); transition: transform .25s ease; }
.side-drawer.is-open { transform: translateX(0); }
.drawer-overlay { position: fixed; z-index: 19; inset: 0; background: rgba(20, 33, 61, .25); backdrop-filter: blur(2px); }
.drawer-heading { display: flex; align-items: flex-start; justify-content: space-between; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.drawer-heading h2 { margin: 0; font-size: 25px; letter-spacing: -1px; }
.close-button { width: 31px; height: 31px; border-radius: 9px; font-size: 25px; line-height: 1; }
.close-button:hover { background: var(--accent-soft); color: var(--accent); }
.drawer-body { padding-top: 12px; }
.drawer-item { padding: 15px 0; display: flex; gap: 11px; align-items: flex-start; border-bottom: 1px solid var(--line); }
.drawer-item-icon { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 9px; color: var(--accent); background: var(--accent-soft); font-size: 12px; }
.drawer-item-copy { min-width: 0; flex: 1; }
.drawer-item-copy strong, .drawer-item-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drawer-item-copy strong { font-size: 11px; }
.drawer-item-copy span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.drawer-action { border: 0; color: #a1abc1; background: transparent; font-size: 14px; }
.drawer-action:hover { color: #ee6573; }
.drawer-empty { padding: 45px 10px; color: var(--muted); text-align: center; font-size: 12px; line-height: 1.7; }

.toast { position: fixed; z-index: 40; left: 50%; bottom: 28px; max-width: calc(100vw - 40px); padding: 11px 16px; border-radius: 10px; color: white; background: var(--ink); font-size: 11px; box-shadow: 0 12px 28px rgba(20, 33, 61, .22); opacity: 0; pointer-events: none; transform: translate(-50%, 12px); transition: .25s ease; }
.toast.visible { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 800px) {
  .app-shell { padding: 18px 12px 15px; gap: 14px; }
  .topbar { padding: 0 4px; }
  .browser-window { min-height: calc(100vh - 122px); border-radius: 18px; }
  .browser-toolbar { padding: 10px 11px; gap: 7px; }
  .navigation-actions { gap: 0; }
  .toolbar-button { width: 29px; }
  .tab-strip { padding-left: 10px; }
  .tab { min-width: 145px; }
  .home-page { padding: 42px 18px 34px; }
  .hero-line { display: block; }
  .time-block { width: fit-content; margin-top: 25px; text-align: left; }
  .search-hero { margin: 34px auto 40px; }
  .search-box { height: 57px; padding-left: 14px; }
  .search-submit { height: 43px; padding: 0 13px; }
  .quick-links { grid-template-columns: repeat(2, 1fr); }
  .bottom-grid { grid-template-columns: 1fr; gap: 32px; margin-top: 35px; }
  .app-footer { padding: 0 4px; display: block; line-height: 1.7; }
  .creator-credit { display: block; }
  .result-page { padding: 35px 20px 45px; }
}

@media (max-width: 480px) {
  .topbar-actions .icon-button { display: none; }
  .brand-mark { width: 34px; height: 34px; }
  .browser-toolbar { flex-wrap: wrap; }
  .address-form { order: 2; flex-basis: 100%; }
  .menu-button { margin-left: auto; }
  .hero-title { letter-spacing: -2.4px; }
  .hero-description { font-size: 12px; }
  .quick-link { padding: 12px; }
  .quick-link small { font-size: 9px; }
}
