:root {
  --bg: #edf3ff;
  --panel: rgba(255, 255, 255, 0.88);
  --panel-soft: rgba(246, 249, 255, 0.92);
  --line: rgba(178, 197, 235, 0.5);
  --line-strong: #b7c7eb;
  --text: #182b56;
  --muted: #64789f;
  --primary: #2342b8;
  --primary-strong: #132f94;
  --teal: #038498;
  --teal-strong: #066979;
  --warm: #fff1df;
  --cool: #ede7ff;
  --hero-aside-start: #e1efff;
  --hero-aside-end: #fff0e4;
  --promo: linear-gradient(90deg, #dffbff, #edf1ff);
  --shadow: 0 28px 70px rgba(38, 70, 130, 0.12);
  --radius-xl: 28px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --sidebar-width: 360px;
  font-family: "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(57, 104, 255, 0.16), transparent 28%),
    radial-gradient(circle at top right, rgba(0, 191, 166, 0.12), transparent 24%),
    linear-gradient(180deg, #f7fbff 0%, #edf3ff 48%, #eef2fb 100%);
}

body.auth-screen .sidebar,
body.auth-screen .sidebar-toggle,
body.auth-screen .topbar {
  display: none;
}

body.auth-screen .app-shell {
  grid-template-columns: 1fr;
}

body.auth-screen .content-area {
  min-height: 100vh;
  padding: 32px;
  display: grid;
  place-items: center;
}

button,
input,
a {
  font: inherit;
}

button {
  border: 0;
  background: none;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  width: 1.2rem;
  height: 1.2rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  min-height: 100vh;
  position: relative;
}

.sidebar {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(245, 249, 255, 0.92));
  border-right: 1px solid var(--line);
  padding: 24px 18px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  backdrop-filter: blur(20px);
  transition: transform 0.28s ease, width 0.28s ease, padding 0.28s ease;
}

.sidebar.collapsed {
  transform: translateX(calc(-1 * var(--sidebar-width) + 72px));
}

.brand-row {
  padding: 6px 10px 12px;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  color: var(--text);
}

.brand-copy strong {
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.brand-copy span {
  font-size: 0.82rem;
  color: var(--muted);
}

.brand-mark {
  width: 50px;
  height: 50px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: #ff6a00;
  background: linear-gradient(135deg, #ffffff, #fff1dd 70%);
  border: 1px solid #ffd3ab;
  box-shadow: 0 14px 28px rgba(255, 132, 26, 0.16);
  font-size: 2.1rem;
  font-weight: 800;
  text-transform: lowercase;
}

.create-button {
  display: block;
  text-align: center;
  width: 100%;
  background: linear-gradient(135deg, #2744bb, #325eea 60%, #1287bd);
  color: #fff;
  border-radius: 18px;
  padding: 22px 18px;
  font-size: 1rem;
  font-weight: 700;
  box-shadow: 0 24px 36px rgba(35, 66, 184, 0.28);
}

.side-nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.nav-item {
  min-height: 60px;
  border-radius: 16px;
  display: grid;
  grid-template-columns: 28px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 0 18px;
  color: #29406d;
  position: relative;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.nav-item:hover {
  background: rgba(233, 241, 255, 0.78);
  transform: translateX(4px);
}

.nav-item.active {
  background: linear-gradient(135deg, #eef4ff, #e4eeff);
  color: #204eb8;
  box-shadow: inset 0 0 0 1px rgba(126, 160, 234, 0.28);
}

.nav-item.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 15px;
  width: 5px;
  height: 30px;
  border-radius: 999px;
  background: #1c50d8;
}

.nav-icon {
  color: currentColor;
}

.nav-label {
  font-size: 1rem;
  font-weight: 700;
}

.nav-badge {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 8px 10px;
}

.try-text {
  color: #546b92;
}

.warm {
  color: #b55f17;
  background: var(--warm);
}

.cool {
  color: #7549d1;
  background: var(--cool);
}

.sidebar-footer {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.settings-item {
  padding-left: 14px;
}

.sidebar-toggle {
  position: fixed;
  left: calc(var(--sidebar-width) - 24px);
  top: 104px;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ffffff, #eef4ff);
  color: var(--text);
  box-shadow: 0 18px 32px rgba(49, 79, 121, 0.24);
  display: grid;
  place-items: center;
  z-index: 30;
  transition: left 0.28s ease, transform 0.28s ease;
}

.sidebar.collapsed + .sidebar-toggle {
  left: 48px;
  transform: rotate(180deg);
}

.main-panel {
  min-width: 0;
}

.topbar {
  height: 126px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(244, 248, 255, 0.76));
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 40px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.topbar-copy {
  min-width: 170px;
}

.eyebrow {
  margin: 0 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.74rem;
  color: var(--muted);
}

.topbar-title {
  margin: 0;
  font-size: 2.3rem;
  letter-spacing: -0.04em;
  line-height: 1;
}

.searchbar {
  flex: 1;
  max-width: 540px;
  height: 62px;
  border-radius: 18px;
  background: rgba(240, 245, 255, 0.88);
  border: 1px solid rgba(180, 198, 236, 0.4);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 20px;
}

.searchbar:focus-within {
  border-color: #9eb8ec;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 16px 30px rgba(57, 104, 255, 0.08);
}

.searchbar input {
  flex: 1;
  border: 0;
  outline: none;
  background: transparent;
  font-size: 1rem;
  color: var(--text);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

.upgrade-button,
.aside-upgrade {
  background: linear-gradient(135deg, #067f93, #0aa5b6);
  color: #fff;
  font-weight: 700;
  border-radius: 14px;
  padding: 16px 24px;
  box-shadow: 0 18px 30px rgba(3, 132, 152, 0.22);
}

.upgrade-button:hover,
.aside-upgrade:hover {
  background: var(--teal-strong);
}

.icon-button {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: var(--text);
}

.sparkle-button {
  color: #394db0;
}

.profile-chip {
  display: flex;
  align-items: center;
  gap: 16px;
}

.avatar {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: linear-gradient(135deg, #22365e, #3b57a0);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
}

.profile-name {
  font-weight: 700;
  white-space: nowrap;
}

.content-area {
  padding: 30px 28px 36px;
}

.creation-tabs {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 28px;
}

.creation-tab {
  height: 58px;
  border-radius: 999px;
  padding: 0 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: #526991;
  font-size: 1rem;
  font-weight: 700;
}

.creation-tab[href] {
  text-decoration: none;
}

.creation-tab.active {
  min-width: 248px;
  justify-content: center;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(241, 246, 255, 0.92));
  color: var(--text);
  box-shadow: 0 16px 30px rgba(61, 88, 142, 0.14);
}

.hero-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(247, 250, 255, 0.9));
  border-radius: 28px;
  border: 1px solid rgba(185, 203, 238, 0.34);
  box-shadow: var(--shadow);
  padding: 36px;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) 420px;
  gap: 34px;
}

.hero-main {
  min-width: 0;
}

.hero-heading {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
}

.hero-heading h1 {
  margin: 0;
  font-size: clamp(2.1rem, 2.8vw, 3rem);
  letter-spacing: -0.04em;
  line-height: 1.1;
}

.meta-line,
.limit-copy {
  margin: 18px 0 0;
  font-size: 1rem;
  color: var(--text);
}

.limit-copy {
  white-space: nowrap;
}

.help-dot {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  background: #203356;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
}

.input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 258px;
  gap: 24px;
  align-items: end;
}

.secondary-row {
  margin-top: 18px;
  align-items: center;
}

.field-label {
  display: block;
  margin-bottom: 16px;
  font-size: 1rem;
  font-weight: 700;
}

.url-input {
  width: 100%;
  height: 60px;
  border-radius: 14px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.92);
  padding: 0 18px;
  font-size: 1rem;
  color: var(--text);
  outline: none;
}

.url-input:focus {
  border-color: #95afe1;
  box-shadow: 0 0 0 4px rgba(31, 84, 214, 0.08);
}

.password-field {
  position: relative;
}

.password-field .url-input {
  padding-right: 92px;
}

.password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  min-width: 64px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #edf3ff, #e3eeff);
  color: #1d4fcf;
  font-weight: 700;
}

.primary-action {
  height: 60px;
  background: linear-gradient(135deg, #3056dd, #173da7);
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  border-radius: 14px;
  box-shadow: 0 18px 28px rgba(42, 91, 232, 0.22);
}

.inline-note {
  min-height: 60px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(236, 244, 255, 0.96), rgba(245, 249, 255, 0.96));
  border: 1px solid #d8e3f7;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 12px 16px;
  line-height: 1.4;
}

.inline-note strong {
  color: var(--text);
  overflow-wrap: anywhere;
}

.checkbox-row {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-top: 26px;
  font-size: 1rem;
}

.checkbox-row input {
  width: 22px;
  height: 22px;
  accent-color: #2a5be8;
}

.promo-strip {
  margin-top: 28px;
  min-height: 60px;
  border-radius: 18px;
  background: var(--promo);
  color: #00748a;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 18px;
  text-align: center;
}

.promo-strip a {
  color: #0d58d6;
  text-decoration: underline;
  font-weight: 700;
}

.result-banner {
  margin-top: 20px;
  border-radius: 12px;
  padding: 16px 18px;
  background: #eef5ff;
  color: #1743a7;
  font-weight: 700;
}

.result-banner.error {
  background: #fff1f0;
  color: #b3402d;
}

.hidden {
  display: none;
}

.hero-aside {
  border-radius: 30px;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.55), transparent 24%),
    linear-gradient(135deg, var(--hero-aside-start), var(--hero-aside-end));
  padding: 36px 28px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
}

.hero-aside h2 {
  margin: 0 0 14px;
  font-size: 1.8rem;
  line-height: 1.15;
}

.hero-aside p {
  margin: 0 0 28px;
  color: #304a73;
  font-size: 1rem;
}

.aside-pill {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(202, 214, 238, 0.88);
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  margin-bottom: 14px;
}

.aside-upgrade {
  margin-top: 12px;
  min-height: 62px;
  border-radius: 8px;
  font-size: 1rem;
}

.bottom-grid {
  margin-top: 38px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
}

.mini-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 250, 255, 0.92));
  border-radius: 24px;
  border: 1px solid rgba(184, 201, 235, 0.34);
  box-shadow: var(--shadow);
  padding: 34px 34px 28px;
}

.surface-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(246, 250, 255, 0.92));
  border-radius: 24px;
  border: 1px solid rgba(184, 201, 235, 0.34);
  box-shadow: var(--shadow);
  padding: 30px;
}

.auth-shell {
  width: min(1180px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
  gap: 28px;
}

.auth-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(246, 250, 255, 0.92));
  border-radius: 28px;
  border: 1px solid rgba(184, 201, 235, 0.34);
  box-shadow: var(--shadow);
}

.auth-copy-card {
  padding: 42px;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.7), transparent 26%),
    linear-gradient(135deg, #e4efff, #fff1e5);
}

.auth-copy-card h1 {
  margin: 0 0 16px;
  font-size: clamp(2.3rem, 4vw, 4rem);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.auth-copy {
  margin: 0 0 28px;
  max-width: 34rem;
  color: #35507e;
  font-size: 1.04rem;
  line-height: 1.7;
}

.auth-feature-list {
  display: grid;
  gap: 16px;
}

.auth-feature {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid rgba(200, 214, 240, 0.8);
}

.auth-form-card {
  padding: 28px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.auth-tab {
  min-height: 50px;
  border-radius: 16px;
  background: #eef4ff;
  color: #587099;
  font-weight: 800;
}

.auth-tab.active {
  background: linear-gradient(135deg, #2141b3, #315fe8);
  color: #fff;
}

.auth-form {
  display: grid;
  gap: 12px;
}

.auth-submit {
  margin-top: 8px;
}

.billing-card h2 {
  margin: 0 0 12px;
  font-size: 2rem;
}

.billing-copy {
  margin: 0 0 18px;
  color: var(--muted);
}

.auth-inline-link {
  justify-self: start;
  padding: 0;
  color: #2b57d8;
  font-weight: 700;
  text-decoration: underline;
}

.auth-google-button {
  min-height: 52px;
  border-radius: 16px;
  border: 1px solid #d7e2f6;
  background: linear-gradient(135deg, #ffffff, #f3f7ff);
  color: var(--text);
  font-weight: 700;
}

.surface-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.surface-header h2 {
  margin: 0 0 8px;
  font-size: 2rem;
  line-height: 1.05;
}

.surface-header p {
  margin: 0;
  color: var(--muted);
}

.chip-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, #eef3ff, #e8f5ff);
  color: #1f52d0;
  font-weight: 700;
}

.mini-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 26px;
}

.mini-card h3 {
  margin: 0;
  font-size: clamp(1.5rem, 2vw, 2rem);
  line-height: 1.1;
}

.mini-card-header a {
  color: #2a5be8;
  font-weight: 700;
}

.integration-list,
.task-list,
.links-list {
  display: grid;
  gap: 18px;
}

.integration-item,
.task-item,
.link-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  color: var(--muted);
}

.integration-item strong,
.task-item span:last-child {
  display: block;
  color: var(--text);
  font-weight: 700;
}

.integration-item p {
  margin: 4px 0 0;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  margin-top: 7px;
  flex: 0 0 auto;
}

.dot.blue {
  background: #2b5de9;
}

.dot.gold {
  background: #f0ae3d;
}

.progress-ring {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  border: 6px solid #dce7fb;
  color: var(--text);
  display: grid;
  place-items: center;
  font-weight: 800;
}

.task-check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 2px solid #d6e2f4;
  flex: 0 0 auto;
}

.task-check.filled {
  background: #2a5be8;
  border-color: #2a5be8;
  position: relative;
}

.task-check.filled::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 2px;
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.empty-state {
  border-radius: 16px;
  background: linear-gradient(135deg, #f7f9fd, #f0f6ff);
  border: 1px dashed #cad6eb;
  padding: 18px;
  color: var(--muted);
}

.link-item {
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  border-radius: 16px;
  background: linear-gradient(135deg, #f9fbff, #f2f7ff);
  border: 1px solid #dce6f6;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.link-copy {
  min-width: 0;
  flex: 1 1 auto;
}

.link-copy strong,
.link-copy a {
  display: block;
}

.link-copy strong {
  margin-bottom: 6px;
  color: var(--text);
  overflow-wrap: anywhere;
}

.link-copy a {
  color: #2a5be8;
  font-weight: 700;
  overflow-wrap: anywhere;
  word-break: break-word;
  line-height: 1.45;
}

.link-copy p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.link-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.link-button {
  min-width: 74px;
  height: 40px;
  border-radius: 10px;
  padding: 0 14px;
  background: linear-gradient(135deg, #edf3ff, #e3eeff);
  color: #1d4fcf;
  font-weight: 700;
}

.link-button.secondary {
  background: linear-gradient(135deg, #eef7f9, #e1fbf7);
  color: #0f7282;
}

.link-button.danger {
  background: #fff1f0;
  color: #b3402d;
}

.domain-stack,
.managed-domain-list {
  display: grid;
  gap: 16px;
}

.domain-pill {
  padding: 14px 16px;
  border-radius: 18px;
  background: linear-gradient(135deg, #f7fbff, #edf4ff);
  border: 1px solid #dce6f6;
}

.domain-pill strong,
.domain-pill span {
  display: block;
}

.domain-pill strong {
  margin-bottom: 6px;
}

.domain-pill span {
  color: var(--muted);
  font-size: 0.92rem;
}

.domain-pill.active {
  background: linear-gradient(135deg, #2141b3, #315fe8 60%, #1390bd);
  color: #fff;
  box-shadow: 0 20px 34px rgba(35, 66, 184, 0.22);
}

.domain-pill.active span {
  color: rgba(255, 255, 255, 0.8);
}

.managed-domain {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-radius: 20px;
  background: linear-gradient(135deg, #f8fbff, #eef5ff);
  border: 1px solid #dce6f6;
}

.managed-domain.active {
  background: linear-gradient(135deg, rgba(35, 66, 184, 0.12), rgba(19, 144, 189, 0.12));
  border-color: #9db7ed;
}

.managed-domain-copy {
  min-width: 0;
}

.managed-domain-copy strong,
.managed-domain-copy span {
  display: block;
  overflow-wrap: anywhere;
}

.managed-domain-copy strong {
  margin-bottom: 8px;
  font-size: 1rem;
}

.managed-domain-copy span {
  color: var(--muted);
  font-size: 0.92rem;
}

.dns-helper-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.dns-helper-grid span {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid #dce6f6;
  color: var(--text);
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

.dns-helper-grid strong {
  color: var(--muted);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.managed-domain-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.domain-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 90px;
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, #2141b3, #315fe8);
  color: #fff;
  font-weight: 700;
}

.domain-select {
  appearance: none;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
  gap: 28px;
}

.stack-card-group {
  display: grid;
  gap: 24px;
}

.inset-card {
  box-shadow: none;
  border: 1px solid #dce6f6;
  padding: 24px;
}

.builder-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.9fr);
  gap: 24px;
}

.form-card,
.preview-card {
  background: linear-gradient(180deg, #f9fbff, #f2f7ff);
  border: 1px solid #dce6f6;
  border-radius: 20px;
  padding: 24px;
}

.form-card {
  display: grid;
  gap: 14px;
}

.preview-card h3 {
  margin: 8px 0 8px;
  font-size: 1.8rem;
}

.preview-card p {
  margin: 0 0 18px;
  color: var(--muted);
}

.helper-copy {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.inline-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 150px;
  padding: 0 20px;
  text-decoration: none;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 28px;
}

.stat-card {
  background: linear-gradient(135deg, #203fa8, #2f65ec 58%, #09a0ab);
  color: #fff;
  border-radius: 22px;
  padding: 24px;
  box-shadow: var(--shadow);
}

.stat-card span {
  display: block;
  opacity: 0.82;
  margin-bottom: 10px;
}

.stat-card strong {
  font-size: 2.4rem;
}

.chart-bars {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 16px;
  align-items: end;
  min-height: 280px;
}

.bar-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  height: 100%;
}

.bar-wrap i {
  display: block;
  width: 100%;
  max-width: 58px;
  background: linear-gradient(180deg, #2d5ae8, #0b7f8b);
  border-radius: 18px 18px 8px 8px;
  margin-top: auto;
}

.campaign-list,
.domain-list {
  display: grid;
  gap: 16px;
}

.campaign-item,
.domain-item {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  border-radius: 16px;
  background: linear-gradient(135deg, #f8fbff, #f1f7ff);
  border: 1px solid #dce6f6;
}

.campaign-item span,
.domain-item span {
  color: var(--muted);
}

.qr-panel {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 24px;
  align-items: center;
}

.qr-box {
  width: 240px;
  height: 240px;
  padding: 18px;
  background: #fff;
  border-radius: 22px;
  border: 1px solid #dce6f6;
  box-shadow: var(--shadow);
}

.qr-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 14px;
}

.qr-grid {
  width: 100%;
  height: 100%;
  border-radius: 14px;
  background:
    linear-gradient(90deg, #1f3257 10%, transparent 10% 20%, #1f3257 20% 30%, transparent 30% 40%, #1f3257 40% 50%, transparent 50% 60%, #1f3257 60% 70%, transparent 70% 80%, #1f3257 80% 90%, transparent 90%),
    linear-gradient(#1f3257 10%, transparent 10% 20%, #1f3257 20% 30%, transparent 30% 40%, #1f3257 40% 50%, transparent 50% 60%, #1f3257 60% 70%, transparent 70% 80%, #1f3257 80% 90%, transparent 90%);
  background-size: 36px 36px;
  background-position: 0 0, 0 0;
}

.qr-copy strong {
  display: block;
  margin-bottom: 10px;
  font-size: 1.05rem;
  overflow-wrap: anywhere;
}

.qr-copy p {
  margin: 0 0 20px;
  color: var(--muted);
}

.qr-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.qr-download {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 140px;
  text-decoration: none;
}

.qr-link-list {
  display: grid;
  gap: 12px;
}

.qr-link-item {
  width: 100%;
  text-align: left;
  padding: 14px 16px;
  border-radius: 16px;
  background: linear-gradient(135deg, #f8fbff, #eef5ff);
  border: 1px solid #dce6f6;
  color: var(--text);
}

.qr-link-item strong,
.qr-link-item span {
  display: block;
  overflow-wrap: anywhere;
}

.qr-link-item strong {
  margin-bottom: 6px;
}

.qr-link-item span {
  color: var(--muted);
  font-size: 0.9rem;
}

.qr-link-item.active {
  background: linear-gradient(135deg, rgba(35, 66, 184, 0.14), rgba(19, 144, 189, 0.12));
  border-color: #9db7ed;
}

.global-banner {
  position: fixed;
  right: 24px;
  bottom: 24px;
  max-width: 360px;
  padding: 14px 18px;
  border-radius: 14px;
  background: #173f9f;
  color: #fff;
  box-shadow: 0 20px 50px rgba(13, 27, 65, 0.24);
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 60;
}

.global-banner.visible {
  opacity: 1;
  transform: translateY(0);
}

.global-banner.error {
  background: #b3402d;
}

.clean-home-shell {
  display: grid;
  gap: 22px;
}

.clean-create-card {
  padding: 28px;
}

.clean-create-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.clean-create-head h2 {
  margin: 0 0 8px;
  font-size: clamp(1.8rem, 2.4vw, 2.4rem);
}

.clean-create-head p {
  margin: 0;
  color: var(--muted);
}

.clean-home-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.clean-create-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 16px;
  align-items: end;
}

.full-span {
  grid-column: 1 / -1;
}

.clean-preview-note {
  min-height: 60px;
}

.clean-checkbox {
  margin-top: 0;
  min-height: 60px;
}

.clean-create-button {
  width: 100%;
}

.clean-recent-card {
  padding-top: 26px;
}

.clean-more-card summary {
  cursor: pointer;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text);
}

.clean-more-card summary::-webkit-details-marker {
  display: none;
}

.clean-more-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 20px;
  margin-top: 18px;
}

.clean-quick-links {
  display: grid;
  gap: 12px;
}

.admin-table {
  display: grid;
  gap: 16px;
}

.admin-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 20px 22px;
  border-radius: 20px;
  background:
    radial-gradient(circle at top right, rgba(74, 134, 255, 0.12), transparent 36%),
    linear-gradient(135deg, rgba(249, 252, 255, 0.96), rgba(238, 245, 255, 0.98));
  border: 1px solid rgba(186, 205, 235, 0.7);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.admin-main {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.admin-main strong {
  font-size: 1.05rem;
  color: var(--text);
}

.admin-main span {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.admin-select,
.admin-days-input {
  height: 40px;
  border-radius: 12px;
  border: 1px solid #d8e3f5;
  background: #fff;
  color: var(--text);
  padding: 0 12px;
  font: inherit;
}

.admin-select {
  min-width: 120px;
}

.admin-days-input {
  width: 88px;
}

.profile-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-badge {
  background: linear-gradient(135deg, #1e3fae, #375eed);
  color: #fff;
}

.profile-card {
  align-self: start;
}

.profile-card-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
}

.profile-card-avatar {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 24px;
  background: linear-gradient(135deg, #2141b3, #11a6bc);
  color: #fff;
  font-size: 2rem;
  font-weight: 800;
  box-shadow: 0 18px 40px rgba(32, 63, 168, 0.25);
}

.profile-card h3 {
  margin: 0 0 6px;
}

.profile-card p {
  margin: 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.analytics-list {
  display: grid;
  gap: 10px;
}

.analytics-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  background: linear-gradient(135deg, #f9fbff, #eef5ff);
  border: 1px solid #dce6f6;
}

.analytics-pill span,
.analytics-pill strong {
  overflow-wrap: anywhere;
}

.analytics-report-grid {
  display: grid;
  gap: 18px;
}

.analytics-report-card a {
  color: #2a5be8;
  overflow-wrap: anywhere;
}

.analytics-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.analytics-meta-grid strong {
  display: block;
  margin-bottom: 10px;
}

.analytics-row.compact {
  padding: 16px 18px;
}

.analytics-actions {
  align-items: flex-start;
}

.analytics-tag {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 6px 12px;
  border-radius: 999px;
  background: #edf3ff;
  color: #2449af;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.analytics-tag.muted {
  background: #f1f6fb;
  color: var(--muted);
  font-weight: 600;
}

@media (max-width: 1320px) {
  .hero-card {
    grid-template-columns: 1fr;
  }

  .hero-aside {
    max-width: 520px;
  }

  .clean-create-grid,
  .clean-more-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1160px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sidebar-width);
    z-index: 40;
    box-shadow: 0 0 0 999px rgba(12, 22, 43, 0.25);
  }

  .sidebar.collapsed {
    transform: translateX(calc(-1 * var(--sidebar-width)));
    box-shadow: none;
  }

  .sidebar-toggle {
    left: 24px;
    top: 24px;
  }

  .sidebar.collapsed + .sidebar-toggle {
    left: 24px;
    transform: rotate(180deg);
  }

  .main-panel {
    width: 100%;
  }

  .topbar {
    padding-left: 88px;
  }
}

@media (max-width: 920px) {
  body.auth-screen .content-area {
    padding: 18px;
    align-items: start;
  }

  .topbar {
    height: auto;
    align-items: stretch;
    flex-direction: column;
    padding: 88px 20px 22px;
  }

  .topbar-actions {
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .content-area {
    padding: 20px;
  }

  .hero-card,
  .mini-card {
    padding: 24px;
  }

  .hero-heading,
  .mini-card-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .clean-create-head {
    flex-direction: column;
  }

  .limit-copy {
    white-space: normal;
  }

  .input-row,
  .bottom-grid,
  .builder-grid,
  .stat-grid,
  .two-column,
  .qr-panel,
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .link-item {
    flex-direction: column;
  }

  .link-actions {
    width: 100%;
  }

  .surface-header,
  .campaign-item,
  .domain-item,
  .managed-domain {
    flex-direction: column;
    align-items: flex-start;
  }

  .managed-domain-actions {
    justify-content: flex-start;
  }

  .dns-helper-grid {
    grid-template-columns: 1fr;
  }

  .admin-row {
    grid-template-columns: 1fr;
  }

  .admin-actions {
    justify-content: flex-start;
  }

  .analytics-meta-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .sidebar {
    width: min(100vw, 420px);
    padding-bottom: 96px;
  }

  .sidebar-footer {
    margin-top: 0;
  }

  .creation-tabs {
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 8px;
  }

  .profile-chip {
    width: 100%;
    justify-content: space-between;
  }

  .promo-strip {
    flex-direction: column;
  }

  .sidebar-toggle {
    left: auto;
    right: 12px;
    top: 18px;
    z-index: 55;
  }

  .sidebar.collapsed + .sidebar-toggle {
    left: auto;
    right: 12px;
  }
}
