:root {
    --background: #0b1220;
    --surface: rgba(17, 24, 42, 0.95);
    --surface-alt: rgba(22, 30, 50, 0.88);
    --primary: #4c9eff;
    --primary-accent: #6ab3ff;
    --focus: #94c6ff;
    --text: #f5f7ff;
    --text-muted: #b0b7d1;
    --border: rgba(255, 255, 255, 0.08);
    --shadow: 0 24px 48px rgba(7, 15, 32, 0.45);
    --radius: 16px;
    --link: #9ec9ff;
    --link-visited: #d6e2ff;
}

* {
    box-sizing: border-box;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
    background: radial-gradient(circle at top left, rgba(76, 158, 255, 0.22), transparent 55%),
        radial-gradient(circle at 20% 80%, rgba(106, 179, 255, 0.18), transparent 60%),
        var(--background);
    color: var(--text);
    display: flex;
    flex-direction: column;
}

a {
    color: var(--link);
    text-decoration: underline;
}

a:visited {
    color: var(--link-visited);
}

a:hover,
a:focus-visible {
    color: var(--primary-accent);
    outline: none;
}

body::before,
body::after {
    content: '';
    position: fixed;
    width: 540px;
    height: 540px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(76, 158, 255, 0.16), transparent 70%);
    filter: blur(0.5px);
    z-index: -1;
}

body::before {
    top: -220px;
    right: -160px;
}

body::after {
    bottom: -260px;
    left: -200px;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 48px;
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(18px);
    background: rgba(11, 18, 32, 0.85);
    border-bottom: 1px solid var(--border);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-decoration: none;
    color: inherit;
}

.logo-mark {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: block;
    object-fit: cover;
    box-shadow: 0 18px 30px rgba(76, 158, 255, 0.28);
}

.logo-text {
    font-size: 1.2rem;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    margin-left: 24px;
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.nav-links a:hover,
.nav-links a:focus {
    color: var(--primary-accent);
}

.nav-links a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--primary-accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a:focus::after,
.nav-links a:active::after {
    transform: scaleX(1);
}

.nav-links .sign-in {
    padding: 10px 20px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary), var(--primary-accent));
    box-shadow: 0 14px 24px rgba(76, 158, 255, 0.26);
}

.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    background: rgba(76, 158, 255, 0.12);
    color: var(--text);
    cursor: pointer;
    transition: border-color 0.3s ease, background 0.3s ease;
}

.menu-toggle:focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 3px;
}

.menu-toggle:hover {
    border-color: rgba(255, 255, 255, 0.25);
    background: rgba(76, 158, 255, 0.22);
}

.menu-icon,
.menu-icon::before,
.menu-icon::after {
    display: block;
    width: 20px;
    height: 2px;
    background: currentColor;
    border-radius: 999px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-icon {
    position: relative;
}

.menu-icon::before,
.menu-icon::after {
    content: '';
    position: absolute;
    left: 0;
}

.menu-icon::before {
    top: -6px;
}

.menu-icon::after {
    top: 6px;
}

.menu-toggle[aria-expanded="true"] .menu-icon {
    background: transparent;
}

.menu-toggle[aria-expanded="true"] .menu-icon::before {
    transform: translateY(6px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-icon::after {
    transform: translateY(-6px) rotate(-45deg);
}

.content {
    flex: 1;
    width: min(1100px, 100%);
    margin: 48px auto 80px;
    padding: 0 32px 80px;
}

.page-nav {
    margin: 0 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.page-nav-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.page-nav-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    border-radius: 999px;
    border: 1px solid rgba(148, 198, 255, 0.25);
    background: rgba(76, 158, 255, 0.08);
    color: var(--primary-accent);
    font-weight: 500;
    text-decoration: none;
    box-shadow: inset 0 0 0 1px rgba(148, 198, 255, 0.05);
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.page-nav-link:hover,
.page-nav-link:focus {
    background: rgba(76, 158, 255, 0.16);
    border-color: rgba(148, 198, 255, 0.45);
    color: #fff;
    transform: translateY(-1px);
}

.page-nav-link:focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 3px;
}

.page-nav-icon {
    display: inline-flex;
    align-items: center;
}

.page-nav-icon svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.hero {
    text-align: center;
    padding: 80px;
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.hero::before,
.hero::after {
    content: '';
    position: absolute;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(76, 158, 255, 0.2), transparent 70%);
    z-index: 0;
}

.hero::before {
    top: -160px;
    left: -120px;
}

.hero::after {
    bottom: -180px;
    right: -150px;
}

.hero h1 {
    font-size: clamp(2.4rem, 4vw, 3.2rem);
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.hero p {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin: 0 auto 40px;
    max-width: 520px;
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

.hero form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    position: relative;
    z-index: 1;
    background: rgba(9, 14, 26, 0.55);
    padding: 32px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 24px 40px rgba(6, 13, 28, 0.45);
}

.hero-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 12px;
    margin-top: 24px;
    text-align: left;
}

.hero-meta__item {
    background: rgba(17, 23, 39, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 14px 16px;
    color: var(--text-muted);
    line-height: 1.5;
}

.form-note {
    font-size: 0.8rem;
    color: #8f98bf;
    margin: 8px 0px 0px 0px;
}

.input-field {
    width: min(420px, 100%);
    padding: 16px 18px;
    border-radius: 14px;
    border: 1px solid rgba(120, 130, 155, 0.25);
    background: rgba(38, 45, 65, 0.9);
    color: var(--text);
    font-size: 1rem;
    transition: border 0.3s ease, box-shadow 0.3s ease;
}

.input-field:focus {
    outline: 2px solid var(--focus);
    outline-offset: 0;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(148, 198, 255, 0.2);
}

.primary-button {
    padding: 14px 26px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    background: linear-gradient(90deg, var(--primary), var(--primary-accent));
    color: #fff;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 16px 28px rgba(76, 158, 255, 0.32);
}

.primary-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 24px 36px rgba(106, 179, 255, 0.34);
}

.primary-button:focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 2px;
}

.section {
    position: relative;
    background: var(--surface);
    border-radius: var(--radius);
    padding: 32px;
    margin-bottom: 32px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.section::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(76, 158, 255, 0.1), transparent 55%);
    pointer-events: none;
}

.section > * {
    position: relative;
    z-index: 1;
}

.section h2 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 1.4rem;
    margin: 0;
}

.section-header {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 20px;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--primary-accent);
    font-weight: 700;
    font-size: 0.8rem;
    margin: 0;
}

.lead {
    color: var(--text-muted);
    line-height: 1.7;
    margin: 4px 0 0;
}

.feature-grid,
.use-case-grid,
.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
}

.feature-card,
.use-case-card,
.faq-card {
    background: rgba(17, 23, 39, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 18px 20px;
    box-shadow: 0 20px 36px rgba(7, 14, 32, 0.32);
    line-height: 1.6;
}

.feature-card h3,
.use-case-card h3,
.faq-card h3 {
    margin: 0 0 8px;
}

.visual-demo {
    margin-top: 24px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    height: 260px;
    background: linear-gradient(135deg, rgba(76, 158, 255, 0.08), rgba(76, 158, 255, 0.02));
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 12px;
    padding: 16px;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05), 0 16px 32px rgba(7, 14, 30, 0.3);
    overflow: hidden;
}

.visual-demo__sidebar {
    background: rgba(12, 19, 33, 0.85);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 12px;
    display: grid;
    gap: 10px;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.visual-demo__logo {
    height: 24px;
    width: 54px;
    border-radius: 6px;
    background: linear-gradient(135deg, rgba(76, 158, 255, 0.7), rgba(109, 76, 255, 0.7));
}

.visual-demo__nav {
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
}

.visual-demo__main {
    background: rgba(12, 19, 33, 0.9);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 14px;
    display: grid;
    gap: 12px;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.visual-demo__toolbar {
    height: 12px;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(76, 158, 255, 0.5), rgba(109, 76, 255, 0.35));
}

.visual-demo__stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
    gap: 10px;
}

.visual-demo__stat {
    height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.visual-demo__board {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
}

.visual-demo__card {
    height: 82px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 10px 18px rgba(6, 12, 24, 0.25);
}

.section--split,
.section--columns {
    display: grid;
    gap: 18px;
}

.section--split {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    align-items: start;
}

.steps {
    list-style: decimal;
    padding-left: 20px;
    margin: 16px 0 0;
    display: grid;
    gap: 10px;
    color: var(--text-muted);
    line-height: 1.6;
}

.step-label {
    display: inline-block;
    font-weight: 700;
    color: var(--text);
    margin-right: 6px;
}

.callout {
    background: rgba(15, 22, 38, 0.9);
    border-radius: 14px;
    padding: 18px 20px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 16px 32px rgba(7, 14, 30, 0.3);
}

.callout--muted {
    background: rgba(14, 20, 34, 0.8);
}

.callout-list {
    margin: 12px 0 0;
    padding-left: 18px;
    color: var(--text-muted);
    display: grid;
    gap: 8px;
}

.section--columns {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    align-items: center;
}

.pricing-summary {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    grid-column: 1 / -1;
    margin-top: 12px;
}

.pricing-grid {
    grid-column: 1 / -1;
}

.pill {
    display: inline-flex;
    align-items: center;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(76, 158, 255, 0.14);
    border: 1px solid rgba(148, 198, 255, 0.3);
    color: var(--primary-accent);
    font-weight: 600;
    gap: 8px;
}

details {
    background: var(--surface-alt);
    border-radius: var(--radius);
    padding: 20px 24px;
    margin-top: 18px;
    border: 1px solid var(--border);
}

details summary {
    cursor: pointer;
    list-style: none;
    font-weight: 600;
    color: var(--text);
}

details[open] summary::after {
    content: '\25B2';
    float: right;
}

details summary::after {
    content: '\25BC';
    float: right;
}

.telegram-alerts-card {
    background: rgba(17, 23, 39, 0.88);
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin: 0 0 24px;
    padding: 0;
    box-shadow: 0 20px 40px rgba(8, 15, 32, 0.28);
    overflow: hidden;
}

.telegram-alerts-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text);
}

.telegram-alerts-summary::after,
.telegram-alerts-card[open] .telegram-alerts-summary::after {
    content: none;
}

.telegram-alerts-heading {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.telegram-alerts-meta {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.telegram-alerts-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    font-weight: 600;
}

.telegram-alerts-status.is-enabled {
    color: var(--primary-accent);
    background: rgba(76, 158, 255, 0.18);
    border: 1px solid rgba(148, 198, 255, 0.32);
}

.telegram-alerts-status.is-disabled {
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.telegram-alerts-caret {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    color: var(--text-muted);
    transition: transform 0.2s ease, color 0.2s ease;
}

.telegram-alerts-caret svg {
    width: 12px;
    height: 12px;
    fill: currentColor;
}

.telegram-alerts-card[open] .telegram-alerts-caret {
    transform: rotate(180deg);
    color: var(--primary-accent);
}

.telegram-alerts-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 0 20px 20px;
}

.telegram-alerts-description {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.6;
}

.telegram-alerts-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0;
}

.telegram-input {
    width: 100%;
    padding: 12px 16px;
    border-radius: 14px;
    border: 1px solid rgba(148, 198, 255, 0.22);
    background: rgba(15, 23, 42, 0.78);
    color: #f8fafc;
    font-size: 0.95rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    box-shadow: inset 0 1px 2px rgba(7, 11, 20, 0.6);
}

.telegram-input::placeholder {
    color: rgba(226, 232, 240, 0.6);
}

.telegram-input:hover {
    border-color: rgba(148, 198, 255, 0.35);
}

.telegram-input:focus {
    outline: none;
    border-color: var(--focus);
    box-shadow: 0 0 0 3px rgba(148, 198, 255, 0.22);
    background: rgba(15, 23, 42, 0.94);
}

.telegram-alerts-form .primary-button {
    align-self: flex-start;
}

.telegram-alerts-instructions-heading {
    margin: 4px 0 0;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: rgba(226, 232, 240, 0.72);
}

.telegram-alerts-list {
    margin: 0 0 12px 20px;
    padding: 0;
    color: var(--text-muted);
    line-height: 1.6;
}

.telegram-alerts-list li {
    margin-bottom: 8px;
}

.telegram-alerts-list li:last-child {
    margin-bottom: 0;
}

.telegram-alerts-note {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.6;
}

.telegram-toggle {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    font-weight: 600;
    color: var(--text);
    user-select: none;
}

.telegram-toggle-switch {
    display: inline-flex;
    align-items: center;
    width: 46px;
    height: 26px;
    border-radius: 999px;
    padding: 3px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.16);
    transition: background 0.25s ease, border-color 0.25s ease;
}

.telegram-toggle-thumb {
    width: 18px;
    height: 18px;
    border-radius: 999px;
    background: #ffffff;
    box-shadow: 0 4px 10px rgba(9, 16, 30, 0.35);
    transition: transform 0.25s ease, background 0.25s ease;
}

.telegram-toggle input:checked + .telegram-toggle-switch {
    background: rgba(76, 158, 255, 0.28);
    border-color: rgba(148, 198, 255, 0.45);
}

.telegram-toggle input:checked + .telegram-toggle-switch .telegram-toggle-thumb {
    transform: translateX(18px);
    background: #f5faff;
}

.telegram-toggle input:focus-visible + .telegram-toggle-switch {
    box-shadow: 0 0 0 3px rgba(148, 198, 255, 0.35);
}

.telegram-toggle-label {
    font-size: 0.95rem;
}

.telegram-alerts-card[open] .telegram-alerts-summary {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 16px;
}

.profile-section-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 16px;
}

.profile-card {
    background: rgba(17, 23, 39, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.profile-card.profile-card--danger {
    background: rgba(255, 99, 71, 0.07);
    border-color: rgba(255, 99, 71, 0.35);
}

.link-collection {
    gap: 12px;
}

.link-note {
    margin: 12px 0 0;
    padding: 12px 14px;
    line-height: 1.6;
    white-space: pre-wrap;
    font-size: 0.9rem;
    color: rgba(222, 229, 255, 0.92);
    background: linear-gradient(135deg, rgba(60, 72, 107, 0.35), rgba(38, 46, 73, 0.65));
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 14px rgba(8, 13, 28, 0.35);
}

.list-item {
    background: rgba(14, 20, 34, 0.85);
    border-radius: 14px;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    gap: 14px;
    backdrop-filter: blur(18px);
}

.project-section-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.plan-grid {
    display: grid;
    gap: 20px;
    margin-top: 32px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.plan-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 24px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(14, 20, 34, 0.9);
    box-shadow: 0 18px 30px rgba(7, 15, 32, 0.32);
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    overflow: hidden;
}

.plan-card:hover,
.plan-card:focus-within {
    transform: translateY(-3px);
    border-color: rgba(76, 158, 255, 0.4);
    box-shadow: 0 28px 46px rgba(9, 18, 34, 0.4);
}

.plan-card--current {
    border-color: rgba(148, 198, 255, 0.45);
    box-shadow: 0 32px 50px rgba(76, 158, 255, 0.28);
}

.plan-card__accent {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle at top right, rgba(76, 158, 255, 0.35), transparent 55%),
        radial-gradient(circle at bottom left, rgba(109, 76, 255, 0.25), transparent 60%);
    opacity: 0.7;
    z-index: 0;
}

.plan-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.plan-card__title {
    margin: 0;
    font-size: 1.4rem;
}

.plan-card__badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(76, 158, 255, 0.18);
    color: var(--primary-accent);
    font-size: 0.8rem;
    font-weight: 600;
    border: 1px solid rgba(148, 198, 255, 0.35);
    position: relative;
    z-index: 1;
}

.plan-card__badge--accent {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.25);
}

.plan-card__price {
    position: relative;
    z-index: 1;
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
}

.plan-card__description {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

.plan-card__features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    color: rgba(228, 233, 255, 0.9);
    position: relative;
    z-index: 1;
}

.plan-card__features li strong {
    color: #fff;
}

.plan-card__actions {
    margin-top: auto;
    position: relative;
    z-index: 1;
}

.primary-button[disabled] {
    cursor: not-allowed;
    opacity: 0.7;
    box-shadow: none;
}

.document-row {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.document-info {
    display: flex;
    flex: 1;
    min-width: 0;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    row-gap: 8px;
}

.document-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    max-width: 100%;
}

.document-link {
    color: var(--text-muted);
    font-weight: 600;
    text-decoration: none;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.document-link:hover,
.document-link:focus-visible {
    color: var(--primary-accent);
    outline: none;
}

.document-size {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.75rem;
}

.document-actions {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.document-actions form {
    margin: 0;
}

.document-type {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.08);
    color: var(--text);
    flex-shrink: 0;
}

.document-type--pdf {
    background: rgba(255, 107, 107, 0.18);
    border-color: rgba(255, 107, 107, 0.35);
    color: #ff8787;
}

.document-type--png {
    background: rgba(56, 217, 169, 0.18);
    border-color: rgba(56, 217, 169, 0.35);
    color: #63e6be;
}

.document-type--jpg {
    background: rgba(116, 192, 252, 0.18);
    border-color: rgba(116, 192, 252, 0.35);
    color: #74c0fc;
}

.document-type--gif {
    background: rgba(252, 196, 25, 0.18);
    border-color: rgba(252, 196, 25, 0.4);
    color: #ffd43b;
}

.document-type--webp {
    background: rgba(81, 207, 102, 0.18);
    border-color: rgba(81, 207, 102, 0.35);
    color: #8ce99a;
}

.document-type--bmp {
    background: rgba(151, 117, 250, 0.18);
    border-color: rgba(151, 117, 250, 0.35);
    color: #b197fc;
}

.document-type--svg {
    background: rgba(247, 131, 172, 0.18);
    border-color: rgba(247, 131, 172, 0.4);
    color: #faa2c1;
}

.document-type--default {
    background: rgba(148, 163, 184, 0.18);
    border-color: rgba(148, 163, 184, 0.3);
    color: #cbd5f5;
}

.link-list-item {
    gap: 10px;
    padding: 16px 18px;
}

.link-list-item.add-new {
    border-style: dashed;
    border-color: rgba(255, 255, 255, 0.1);
}

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

.link-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    flex: 1;
}

.link-info .link-title {
    color: var(--text);
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

.link-info .link-title:hover,
.link-info .link-title:focus-visible {
    color: var(--primary-accent);
    outline: none;
}

.link-url {
    color: var(--text-muted);
    font-size: 0.8rem;
    word-break: break-all;
}

.link-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.icon-button {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    cursor: pointer;
    transition: color 0.2s ease, border 0.2s ease, background 0.2s ease;
}

.icon-button svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

.icon-button:hover,
.icon-button:focus-visible {
    color: var(--primary-accent);
    border-color: rgba(76, 158, 255, 0.6);
    background: rgba(76, 158, 255, 0.12);
    outline: none;
}

.icon-button.danger {
    color: #ff8b8b;
    border-color: rgba(255, 139, 139, 0.4);
    background: rgba(255, 139, 139, 0.08);
}

.icon-button.danger:hover,
.icon-button.danger:focus-visible {
    color: #ffb0b0;
    border-color: rgba(255, 176, 176, 0.6);
    background: rgba(255, 139, 139, 0.16);
}

.icon-form {
    margin: 0;
}

.link-edit-form {
    display: grid;
    gap: 10px;
}



.link-edit-form[hidden] {
    display: none;
}

.project-edit-form[hidden],
.project-delete-form[hidden] {
    display: none;
}

[data-project-edit-target],
[data-project-delete-target] {
    display: none;
}

[data-project-edit-target][data-panel-open],
[data-project-delete-target][data-panel-open] {
    display: grid;
}

[data-collapsible-target][hidden] {
    display: none !important;
}

.link-edit-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.collapsible-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.project-overview {
    background: rgba(17, 23, 39, 0.85);
    display: grid;
    gap: 16px;
}

.project-overview-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.project-overview-details {
    display: grid;
    gap: 16px;
    flex: 1 1 260px;
    min-width: 0;
}

.project-overview-actions {
    align-items: flex-start;
}

.project-overview-text {
    color: var(--text-muted);
    margin: 8px 0 0;
}

.project-edit-form,
.project-delete-form {
    background: rgba(17, 23, 39, 0.85);
    padding: 24px;
    border-radius: 12px;
    gap: 12px;
}

.project-edit-actions,
.project-delete-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.form-label-help {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.8rem;
    margin-left: 6px;
}

.toggle-control {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 8px 0 0;
    cursor: pointer;
    user-select: none;
}

.toggle-control input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    border-radius: 6px;
}

.toggle-label {
    font-weight: 500;
    color: var(--text);
}

.form-help-text {
    margin: 6px 0 18px;
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.integration-section {
    background: linear-gradient(135deg, rgba(76, 158, 255, 0.12), rgba(17, 24, 40, 0.95));
    border: 1px solid rgba(148, 198, 255, 0.18);
    border-radius: 20px;
    padding: 28px;
    margin-top: 32px;
    box-shadow: 0 24px 46px rgba(8, 15, 32, 0.35);
}

.integration-toggle-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 24px;
    margin-bottom: 24px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(76, 158, 255, 0.16), rgba(25, 35, 58, 0.92));
    border: 1px solid rgba(148, 198, 255, 0.22);
    box-shadow: 0 18px 40px rgba(7, 15, 32, 0.28);
    flex-wrap: wrap;
}

.integration-toggle-info {
    display: flex;
    align-items: center;
    gap: 18px;
    flex: 1 1 320px;
    min-width: 0;
}

.integration-toggle-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(76, 158, 255, 0.24), rgba(106, 179, 255, 0.18));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 0 1px rgba(148, 198, 255, 0.18);
}

.integration-toggle-icon svg {
    width: 28px;
    height: 28px;
    fill: #fff;
}

.integration-toggle-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 6px;
}

.integration-toggle-text {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.5;
}

.integration-toggle-controls {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.integration-toggle-controls .integration-status {
    flex-shrink: 0;
}

.integration-toggle-form {
    display: flex;
    align-items: center;
}

.integration-toggle-form button {
    min-width: 160px;
}

@media (max-width: 640px) {
    .integration-toggle-card {
        padding: 20px;
        gap: 20px;
    }

    .integration-toggle-controls {
        width: 100%;
        justify-content: space-between;
    }

    .integration-toggle-form {
        width: 100%;
    }

    .integration-toggle-form button {
        width: 100%;
    }
}

.integration-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.integration-summary-info {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.integration-summary-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
}

.integration-summary-row [data-collapsible-trigger] {
    flex-shrink: 0;
}

.integration-summary-toggle {
    width: 36px;
    height: 36px;
}

.integration-summary-toggle svg {
    width: 18px;
    height: 18px;
    transform-origin: 50% 50%;
    transition: transform 0.2s ease;
}

[data-collapsible].collapsible-open .integration-summary-toggle svg {
    transform: rotate(180deg);
}

.integration-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.integration-header h2 {
    margin: 0;
}

.integration-subtitle {
    margin: 6px 0 0;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.95rem;
    line-height: 1.6;
}

.integration-status {
    padding: 8px 16px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.integration-status.status-active {
    background: rgba(109, 252, 180, 0.18);
    color: #d5ffe7;
    border: 1px solid rgba(109, 252, 180, 0.4);
}

.integration-status.status-disabled {
    background: rgba(255, 193, 111, 0.16);
    color: #ffe3bc;
    border: 1px solid rgba(255, 193, 111, 0.35);
}

.integration-description {
    margin: 18px 0;
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
}

.integration-details {
    margin-top: 24px;
}

.snippet-card {
    background: rgba(9, 15, 28, 0.88);
    border: 1px solid rgba(148, 198, 255, 0.22);
    border-radius: 16px;
    padding: 18px;
    margin-top: 16px;
}

.snippet-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-weight: 600;
    color: var(--text);
}

.snippet-card-header--simple {
    justify-content: flex-end;
}

.copy-snippet {
    border: 1px solid rgba(148, 198, 255, 0.4);
    background: rgba(76, 158, 255, 0.14);
    color: var(--text);
    border-radius: 999px;
    padding: 6px 16px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.copy-snippet:hover,
.copy-snippet:focus-visible {
    background: rgba(76, 158, 255, 0.22);
    border-color: rgba(148, 198, 255, 0.65);
    transform: translateY(-1px);
    outline: none;
}

.integration-code {
    margin: 0;
    background: none;
    border: none;
    padding: 0;
}

.integration-actions {
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
}

.integration-note {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.integration-hero .integration-note {
    margin-top: 20px;
}

.integration-hero {
    background: linear-gradient(135deg, rgba(76, 158, 255, 0.16), rgba(17, 24, 40, 0.92));
    border: 1px solid rgba(148, 198, 255, 0.18);
    border-radius: 24px;
    padding: 32px;
    margin-bottom: 32px;
    box-shadow: 0 24px 52px rgba(7, 13, 26, 0.35);
}

.integration-guide-layout {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.integration-guide-nav {
    position: sticky;
    top: 120px;
    min-width: 220px;
    padding-right: 28px;
    border-right: 1px solid rgba(148, 198, 255, 0.22);
}

.integration-guide-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.integration-guide-nav > ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.integration-guide-nav li {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.integration-guide-nav li > a {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 12px;
    color: var(--text-muted);
    text-decoration: none;
    border: 1px solid transparent;
    transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
    font-weight: 600;
    width: 100%;
}

.integration-guide-nav ul ul {
    border-left: 1px solid rgba(148, 198, 255, 0.18);
    margin-left: 12px;
    padding-left: 14px;
    gap: 6px;
    display: flex;
    flex-direction: column;
}

.integration-guide-nav ul ul li {
    gap: 6px;
}

.integration-guide-nav ul ul a {
    border-radius: 10px;
    padding: 8px 12px;
    font-weight: 500;
}

.integration-guide-nav a:hover,
.integration-guide-nav a:focus-visible {
    color: var(--text);
    background: rgba(76, 158, 255, 0.18);
    border-color: rgba(76, 158, 255, 0.35);
    outline: none;
}

.integration-guide-content {
    flex: 1;
    min-width: 0;
}

.integration-guide-content [id] {
    scroll-margin-top: 120px;
}

.integration-hero-title {
    margin: 18px 0 12px;
    font-size: 2rem;
}

.integration-hero-subtitle {
    margin: 0 0 24px;
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.7;
}

.guide-steps {
    counter-reset: step;
    margin: 28px 0 0;
    padding-left: 0;
    list-style: none;
    display: grid;
    gap: 16px;
}

.guide-steps li {
    position: relative;
    background: rgba(9, 15, 28, 0.9);
    border: 1px solid rgba(148, 198, 255, 0.18);
    border-radius: 14px;
    padding: 18px 18px 18px 64px;
    line-height: 1.6;
    color: var(--text-muted);
}

.guide-steps li::before {
    counter-increment: step;
    content: counter(step);
    position: absolute;
    top: 18px;
    left: 22px;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--primary-accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: #fff;
}

.guide-section {
    background: rgba(17, 24, 40, 0.92);
    border-radius: 20px;
    border: 1px solid rgba(148, 198, 255, 0.12);
    padding: 28px;
    margin-bottom: 28px;
}

.guide-section h2 {
    margin-top: 0;
    margin-bottom: 18px;
}

.guide-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

.guide-card {
    background: rgba(9, 15, 28, 0.88);
    border: 1px solid rgba(148, 198, 255, 0.18);
    border-radius: 16px;
    padding: 18px;
    display: grid;
    gap: 12px;
}

.guide-card h3 {
    margin: 0;
}

.guide-card p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.6;
}

.guide-grid h4 {
    margin: 0 0 6px;
}

@media (max-width: 1040px) {
    .integration-guide-nav {
        padding-right: 22px;
    }
}

@media (max-width: 960px) {
    .integration-guide-layout {
        flex-direction: column;
        gap: 28px;
    }

    .integration-guide-nav {
        position: static;
        width: 100%;
        padding: 18px 22px;
        border-right: none;
        border: 1px solid rgba(148, 198, 255, 0.16);
        border-radius: 18px;
        background: rgba(17, 24, 40, 0.85);
    }

    .integration-guide-nav > ul {
        gap: 14px;
    }

    .integration-guide-nav li {
        gap: 10px;
    }

    .integration-guide-nav ul ul {
        margin-left: 0;
        padding-left: 16px;
    }
}

@media (max-width: 720px) {
    .guide-section {
        padding: 22px;
    }

    .snippet-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

@media (max-width: 520px) {
    .guide-section {
        padding: 18px;
    }

    .integration-guide-nav {
        padding: 16px;
    }

    .integration-guide-nav li > a {
        font-size: 0.95rem;
    }

    .integration-guide-nav ul ul a {
        font-size: 0.9rem;
    }

    .code-block {
        font-size: 0.85rem;
    }
}

.guide-card .code-block {
    margin: 0;
    max-height: 260px;
}

.guide-tips {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
}

.tip-card {
    background: rgba(9, 15, 28, 0.88);
    border: 1px solid rgba(148, 198, 255, 0.18);
    border-radius: 16px;
    padding: 20px;
    display: grid;
    gap: 10px;
}

.tip-card h3 {
    margin: 0;
}

.tip-card p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.6;
}

.project-edit-actions {
    justify-content: flex-end;
}

.project-delete-actions {
    justify-content: flex-start;
}

.collapsible-body {
    margin-top: 12px;
}

[data-collapsible] > [data-collapsible-trigger] {
    align-self: flex-start;
}

[data-collapsible].collapsible-open > [data-collapsible-trigger] {
    display: none;
}

.primary-button.small-button {
    padding: 10px 18px;
    font-size: 0.9rem;
    box-shadow: 0 12px 22px rgba(76, 158, 255, 0.28);
}

.text-button {
    background: none;
    border: none;
    color: var(--text-muted);
    font-weight: 500;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 8px;
    transition: color 0.2s ease, background 0.2s ease;
}

.text-button:hover,
.text-button:focus-visible {
    color: var(--primary-accent);
    background: rgba(76, 158, 255, 0.12);
    outline: none;
}

.link-list-item.editing .link-row {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding-bottom: 8px;
}

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

.list-item label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.list-item input,
.list-item textarea,
.form-control {
    width: 100%;
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(11, 17, 31, 0.95);
    color: var(--text);
}

.project-tasks-card {
    gap: 16px;
}

.project-tasks-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.project-tasks-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.project-task-summary-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0;
    padding: 0;
}

.project-task-summary-list li {
    margin: 0;
}

.notes-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.notes-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.note-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.note-card {
    background: rgba(11, 17, 31, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 10px;
    color: inherit;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    font: inherit;
    width: 100%;
    background-clip: padding-box;
}

.note-card:hover,
.note-card:focus-visible {
    border-color: rgba(148, 198, 255, 0.6);
    box-shadow: 0 0 0 2px rgba(76, 158, 255, 0.15);
}

.note-card:focus-visible {
    outline: none;
}

.note-card-title {
    font-weight: 600;
    font-size: 1rem;
}

.note-card-preview {
    font-size: 0.9rem;
    color: rgba(226, 232, 240, 0.9);
    line-height: 1.5;
    white-space: pre-line;
}

.notes-empty {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.task-chip {
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(15, 23, 42, 0.9);
    color: inherit;
    padding: 14px 16px;
    border-radius: 14px;
    cursor: pointer;
    min-width: 220px;
    max-width: 260px;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.task-chip:hover,
.task-chip:focus-visible {
    border-color: rgba(148, 198, 255, 0.6);
    transform: translateY(-2px);
    outline: none;
}

.task-chip-title {
    font-weight: 600;
    font-size: 1rem;
}

.task-chip-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.task-summary-empty {
    margin: 0;
    color: var(--text-muted);
}

.task-modal[hidden] {
    display: none !important;
}

.task-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(8, 12, 23, 0.72);
    backdrop-filter: blur(8px);
    z-index: 40;
    padding: 32px 24px;
}

.task-modal.is-open {
    display: flex;
}

.task-modal-content {
    background: rgba(16, 22, 36, 0.96);
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 30px 55px rgba(10, 16, 32, 0.5);
    width: min(520px, 100%);
    padding: 28px;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
}

.task-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.task-modal-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.task-modal-close {
    border: none;
    background: rgba(148, 198, 255, 0.12);
    color: var(--text);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
}

.task-delete-form {
    margin: 0;
}

.task-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.task-form-grid {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.task-form-grid > div {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.task-modal-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: flex-end;
    margin-top: 8px;
}

.event-modal[hidden] {
    display: none !important;
}

.event-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(8, 12, 23, 0.72);
    backdrop-filter: blur(8px);
    z-index: 50;
    padding: 32px 24px;
}

.event-modal.is-open {
    display: flex;
}

.event-modal-content {
    background: rgba(16, 22, 36, 0.96);
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 30px 55px rgba(10, 16, 32, 0.5);
    width: min(520px, 100%);
    padding: 28px;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
}

.event-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.event-modal-close {
    border: none;
    background: rgba(148, 198, 255, 0.12);
    color: var(--text);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
}

.event-modal-body {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.event-modal-list {
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.event-modal-list-item {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 12px;
}

.event-modal-list-item dt {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.event-modal-list-item dd {
    margin: 0;
    font-size: 1rem;
    word-break: break-word;
}

.event-modal-list-item a[aria-disabled="true"] {
    color: var(--text-muted);
    pointer-events: none;
    cursor: default;
    text-decoration: none;
}

.event-modal-props h3 {
    margin: 0 0 8px;
    font-size: 1rem;
}

.event-modal-props-content {
    margin: 0;
    padding: 16px;
    background: rgba(12, 18, 30, 0.9);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    font-family: 'Fira Code', 'Consolas', 'Menlo', monospace;
    font-size: 0.85rem;
    line-height: 1.4;
    white-space: pre-wrap;
    overflow-x: auto;
}

.event-modal-props-empty {
    margin: 0;
    color: var(--text-muted);
}

.event-modal-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 24px;
}

.confirm-modal[hidden] {
    display: none !important;
}

.confirm-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(8, 12, 23, 0.72);
    backdrop-filter: blur(8px);
    z-index: 55;
    padding: 32px 24px;
}

.confirm-modal.is-open {
    display: flex;
}

.confirm-modal__content {
    background: rgba(16, 22, 36, 0.96);
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 30px 55px rgba(10, 16, 32, 0.5);
    width: min(520px, 100%);
    padding: 28px;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
}

.confirm-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.confirm-modal__title {
    margin: 0;
    font-size: 1.25rem;
}

.confirm-modal__close {
    border: none;
    background: rgba(148, 198, 255, 0.12);
    color: var(--text);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
}

.confirm-modal__body {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.confirm-modal__list {
    margin: 0;
    padding-left: 18px;
    color: var(--text-muted);
    line-height: 1.5;
}

.confirm-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 8px;
}

body.is-confirm-modal-open {
    overflow: hidden;
}

body.is-event-modal-open {
    overflow: hidden;
}

.task-board {
    display: grid;
    gap: 20px;
    margin-top: 24px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.task-column {
    background: rgba(14, 20, 34, 0.9);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-height: 260px;
}

.task-column-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.task-column-header h2 {
    margin: 0;
    font-size: 1.1rem;
}

.task-column-count {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.task-column-body,
.task-backlog-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.task-column-empty {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.task-card {
    background: rgba(11, 17, 31, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.task-card-body {
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    color: inherit;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 8px;
    cursor: pointer;
}

.task-card-body:focus-visible {
    outline: 2px solid var(--focus);
    border-radius: 10px;
    outline-offset: 4px;
}

.task-card-title {
    font-weight: 600;
    font-size: 1rem;
}

.task-card-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.task-card-description {
    margin: 0;
    font-size: 0.9rem;
    color: rgba(226, 232, 240, 0.9);
    line-height: 1.5;
}

.task-status-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tasks-page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.tasks-page-subtitle {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.tasks-page-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.task-backlog,
.task-done {
    margin-top: 32px;
    background: rgba(14, 20, 34, 0.9);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.task-backlog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

@media (max-width: 640px) {
    .task-modal-content {
        padding: 24px 20px;
    }

    .task-board {
        grid-template-columns: 1fr;
    }

    .task-chip {
        min-width: 100%;
        max-width: 100%;
    }
}

.actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.secondary-button,
.danger-button {
    padding: 10px 16px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s ease, transform 0.2s ease;
}

.secondary-button {
    background: rgba(76, 158, 255, 0.18);
    color: var(--text);
    text-decoration: none;
}

.secondary-button:hover {
    background: rgba(106, 179, 255, 0.32);
    transform: translateY(-1px);
    text-decoration: none;
}

.secondary-button.small-button {
    padding: 9px 16px;
    font-size: 0.9rem;
    box-shadow: 0 12px 22px rgba(76, 158, 255, 0.22);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.section-header h2 {
    margin: 0;
}

.danger-button {
    background: rgba(255, 87, 110, 0.2);
    color: #ff576e;
}

.danger-button:hover {
    background: rgba(255, 87, 110, 0.35);
    transform: translateY(-1px);
}

.grid-two-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
}

.project-card {
    padding: 24px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(15, 22, 36, 0.92);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    text-decoration: none;
    color: inherit;
    backdrop-filter: blur(16px);
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 32px rgba(12, 20, 36, 0.5);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.75rem;
    background: rgba(76, 158, 255, 0.18);
    color: var(--text);
}

.site-footer {
    margin-top: auto;
    padding: 32px 48px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(11, 18, 32, 0.85);
    border-top: 1px solid var(--border);
    backdrop-filter: blur(18px);
}

.site-footer a {
    color: var(--text-muted);
    text-decoration: none;
    margin-right: 18px;
}

.site-footer a:hover {
    color: var(--primary-accent);
}

.alert {
    background: rgba(255, 87, 110, 0.15);
    color: #ffb3bd;
    padding: 14px 18px;
    border-radius: 12px;
    border: 1px solid rgba(255, 87, 110, 0.3);
    margin-bottom: 20px;
}

.success {
    background: rgba(109, 252, 180, 0.18);
    color: #d5ffe7;
    padding: 14px 18px;
    border-radius: 12px;
    border: 1px solid rgba(109, 252, 180, 0.3);
    margin-bottom: 20px;
}

.table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 16px;
}

.table th,
.table td {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    text-align: left;
}

.table tbody tr:hover {
    background: rgba(76, 158, 255, 0.12);
}

.code-block {
    background: linear-gradient(135deg, rgba(24, 36, 62, 0.95), rgba(9, 17, 31, 0.95));
    border: 1px solid rgba(88, 130, 234, 0.35);
    box-shadow: 0 18px 30px rgba(8, 14, 28, 0.45);
    border-radius: 14px;
    padding: 16px;
    max-height: 220px;
    overflow: auto;
    font-family: 'JetBrains Mono', 'SFMono-Regular', ui-monospace, Menlo, Monaco, Consolas, monospace;
    font-size: 0.9rem;
    white-space: pre-wrap;
    color: #d8e4ff;
    line-height: 1.6;
    position: relative;
}

.code-block::before {
    content: '';
    position: absolute;
    inset: 1px;
    border-radius: 12px;
    pointer-events: none;
    background: radial-gradient(circle at 15% 20%, rgba(107, 197, 255, 0.12), transparent 55%),
        radial-gradient(circle at 85% 30%, rgba(170, 139, 255, 0.12), transparent 60%);
    mix-blend-mode: screen;
}

.code-block code,
.code-block span,
.code-block strong {
    color: inherit;
}

.code-block .code-accent {
    color: #8ad8ff;
}

.code-block .code-muted {
    color: rgba(216, 228, 255, 0.65);
}

.analytics-section {
    padding: 28px;
}

.analytics-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.analytics-subtitle {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.analytics-chart,
.visitor-chart {
    position: relative;
    min-height: 240px;
    border-radius: 22px;
    background: radial-gradient(circle at top, rgba(56, 189, 248, 0.16), rgba(8, 14, 26, 0.9));
    border: 1px solid rgba(148, 198, 255, 0.2);
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.25), 0 24px 36px rgba(15, 23, 42, 0.45);
    overflow: visible;
}

.analytics-chart-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.analytics-chart-footer {
    display: flex;
    justify-content: flex-end;
}

.events-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.events-title {
    margin: 0;
    font-size: 1.6rem;
}

.events-subtitle {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.collapsible-card {
    background: rgba(17, 23, 39, 0.88);
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin: 0 0 24px;
    padding: 0;
    box-shadow: 0 18px 36px rgba(7, 15, 32, 0.3);
    overflow: hidden;
}

.collapsible-card-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    list-style: none;
}

.collapsible-card-summary:focus-visible {
    outline: 2px solid rgba(148, 198, 255, 0.7);
    outline-offset: 2px;
}

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

.collapsible-card-title {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.collapsible-card-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.collapsible-card-icon svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    transform-origin: 50% 50%;
    transition: transform 0.2s ease;
}

.collapsible-card[open] .collapsible-card-icon {
    color: var(--primary-accent);
}

.collapsible-card[open] .collapsible-card-icon svg {
    transform: rotate(90deg);
}

.collapsible-card[open] .collapsible-card-summary {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.collapsible-card-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 0 20px 20px;
}

.collapsible-card-description {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.6;
}

.collapsible-card-note {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.events-api-secret {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.events-api-secret-value {
    font-size: 0.95rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 6px 10px;
    border-radius: 6px;
    letter-spacing: 0.03em;
    word-break: break-all;
}

.events-api-secret-form {
    margin: 0;
}

.events-api-secret-form .secondary-button,
.events-api-card .secondary-button {
    white-space: nowrap;
}

.events-table td {
    vertical-align: top;
}

.event-time {
    font-weight: 600;
    color: rgba(226, 232, 240, 0.9);
}

.event-page-link {
    display: inline-flex;
    flex-direction: column;
    gap: 2px;
    color: rgba(226, 232, 240, 0.9);
    text-decoration: none;
}

.event-page-link:hover .event-page-path,
.event-page-link:hover .event-page-query,
.event-page-link:focus-visible .event-page-path,
.event-page-link:focus-visible .event-page-query {
    color: rgba(148, 198, 255, 0.9);
}

.event-page-path {
    font-weight: 500;
}

.event-page-query {
    font-size: 0.82rem;
    color: rgba(226, 232, 240, 0.65);
}

.events-empty-state {
    border-radius: 18px;
    background: rgba(12, 19, 33, 0.85);
    border: 1px solid rgba(148, 198, 255, 0.18);
    padding: 32px 28px;
    text-align: center;
    color: rgba(226, 232, 240, 0.8);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.events-empty-state h3 {
    margin: 0;
    font-size: 1.2rem;
    color: #f4f6ff;
}

.events-empty-state p {
    margin: 0;
    color: rgba(226, 232, 240, 0.75);
}

.analytics-chart::before,
.visitor-chart::before {
    content: "";
    position: absolute;
    inset: 0;
    mix-blend-mode: screen;
    pointer-events: none;
    opacity: 0.8;
    border-radius: inherit;
}

.analytics-chart::before {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.22), rgba(29, 78, 216, 0));
}

.visitor-chart::before {
    background: linear-gradient(135deg, rgba(244, 114, 182, 0.24), rgba(99, 102, 241, 0));
}

.analytics-chart canvas,
.visitor-chart canvas {
    position: relative;
    z-index: 1;
    display: block;
    width: 100%;
    height: 100%;
    border-radius: inherit;
}

.chart-tooltip {
    position: absolute;
    left: 0;
    top: 0;
    transform: translate(-50%, -120%);
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.95);
    color: #f8fafc;
    border: 1px solid rgba(148, 198, 255, 0.4);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.55);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.18s ease, transform 0.18s ease;
    font-size: 0.85rem;
    z-index: 5;
    white-space: nowrap;
}

.chart-tooltip[data-visible="true"] {
    opacity: 1;
    transform: translate(-50%, -135%);
}

.chart-tooltip::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -6px;
    width: 10px;
    height: 10px;
    background: inherit;
    border-left: 1px solid rgba(148, 198, 255, 0.4);
    border-bottom: 1px solid rgba(148, 198, 255, 0.4);
    transform: translate(-50%, 0) rotate(45deg);
}

.chart-tooltip-label {
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: rgba(226, 232, 240, 0.75);
    margin-bottom: 4px;
}

.chart-tooltip-value {
    font-weight: 600;
    font-size: 1rem;
    color: #e0f2fe;
}

.analytics-list {
    background: rgba(12, 19, 33, 0.85);
    border: 1px solid rgba(148, 198, 255, 0.12);
    border-radius: 16px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.analytics-list-title {
    margin: 0;
    font-size: 1rem;
}

.compact-activity-list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.compact-activity-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.compact-activity-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.compact-activity-title {
    font-weight: 600;
    word-break: break-word;
}

.compact-activity-link {
    font-size: 0.9rem;
    color: var(--link);
    text-decoration: underline;
    word-break: break-all;
}

.compact-activity-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.analytics-empty {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

.analytics-empty-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 20px 22px;
    border-radius: 18px;
    background: radial-gradient(120% 140% at 10% 0%, rgba(106, 179, 255, 0.22), rgba(18, 25, 40, 0.92));
    border: 1px solid rgba(106, 179, 255, 0.28);
    box-shadow: 0 18px 40px rgba(7, 14, 26, 0.4);
}

.analytics-empty-icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(148, 198, 255, 0.35);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    line-height: 1;
}

.analytics-empty-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.analytics-empty-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
    color: #f4f6ff;
}

.analytics-empty-text {
    margin: 0;
    color: rgba(226, 236, 255, 0.82);
    font-size: 0.96rem;
    line-height: 1.6;
}

.analytics-empty-example {
    margin: 0;
    font-size: 0.9rem;
}

.analytics-empty-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.visitor-analytics-section {
    margin-top: 24px;
    background: radial-gradient(120% 120% at 20% 0%, rgba(76, 106, 255, 0.14), rgba(18, 25, 40, 0.92));
    border-radius: 24px;
    border: 1px solid rgba(148, 198, 255, 0.18);
}

.visitor-analytics-header {
    gap: 12px;
}

.visitor-summary-range {
    padding: 6px 14px;
    border-radius: 999px;
    background: rgba(148, 198, 255, 0.14);
    border: 1px solid rgba(148, 198, 255, 0.25);
    font-size: 0.85rem;
    color: rgba(229, 238, 255, 0.85);
    white-space: nowrap;
}

.visitor-analytics-card {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.visitor-metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 18px;
}

.visitor-metric {
    padding: 18px 20px;
    border-radius: 18px;
    background: rgba(12, 19, 33, 0.8);
    border: 1px solid rgba(148, 198, 255, 0.14);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.visitor-metric-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(226, 232, 240, 0.6);
}

.visitor-metric-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: #f1f5ff;
}

.visitor-metric-hint {
    font-size: 0.9rem;
    color: rgba(226, 232, 240, 0.7);
}

.visitor-chart-card {
    border-radius: 20px;
    background: rgba(12, 19, 33, 0.85);
    border: 1px solid rgba(148, 198, 255, 0.12);
    padding: 24px;
}

.visitor-chart {
    min-height: 280px;
}

.visitor-chart-toolbar {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-end;
    padding: 6px;
    margin-bottom: 12px;
    border-radius: 999px;
    background: rgba(148, 198, 255, 0.12);
    border: 1px solid rgba(148, 198, 255, 0.18);
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.3);
}

.visitor-chart-toggle {
    appearance: none;
    border: none;
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: rgba(226, 232, 240, 0.8);
    background: transparent;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.visitor-chart-toggle:hover {
    background: rgba(148, 198, 255, 0.24);
    color: #f8fafc;
}

.visitor-chart-toggle.is-active {
    background: linear-gradient(135deg, rgba(192, 132, 252, 0.6), rgba(148, 163, 255, 0.55));
    color: #0f172a;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.45);
}

.visitor-chart-toggle:focus-visible {
    outline: 2px solid rgba(148, 198, 255, 0.8);
    outline-offset: 2px;
}

.visitor-list-card,
.events-table-card {
    border-radius: 20px;
    background: rgba(12, 19, 33, 0.85);
    border: 1px solid rgba(148, 198, 255, 0.12);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: flex-end;
    margin-bottom: 20px;
    padding: 20px 24px;
    border-radius: 18px;
    background: linear-gradient(145deg, rgba(12, 18, 31, 0.92), rgba(16, 24, 40, 0.86));
    border: 1px solid rgba(148, 198, 255, 0.18);
    box-shadow: 0 22px 44px rgba(7, 15, 32, 0.35);
}

.filter-field {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 200px;
    flex: 1 1 220px;
}

.filter-field--search {
    flex: 2 1 320px;
}

.filter-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-weight: 600;
    color: rgba(226, 232, 240, 0.64);
}

.filter-select-wrapper,
.filter-search-wrapper,
.task-select-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.filter-select,
.filter-input,
.task-select {
    width: 100%;
    padding: 12px 16px;
    border-radius: 14px;
    border: 1px solid rgba(148, 198, 255, 0.22);
    background: rgba(15, 23, 42, 0.78);
    color: #f8fafc;
    font-size: 0.95rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    box-shadow: inset 0 1px 2px rgba(7, 11, 20, 0.6);
}

.filter-select:hover,
.filter-input:hover,
.task-select:hover {
    border-color: rgba(148, 198, 255, 0.35);
}

.filter-select:focus,
.filter-input:focus,
.task-select:focus {
    outline: none;
    border-color: var(--focus);
    box-shadow: 0 0 0 3px rgba(148, 198, 255, 0.22);
    background: rgba(15, 23, 42, 0.94);
}

.filter-select,
.task-select {
    appearance: none;
    padding-right: 48px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20' stroke='%23b0b7d1' stroke-width='1.6'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 14px;
}

.filter-search-wrapper::before {
    content: '';
    position: absolute;
    left: 18px;
    top: 50%;
    width: 16px;
    height: 16px;
    transform: translateY(-50%);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23b0b7d1' stroke-width='1.8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M21 21l-4.35-4.35M19 11a8 8 0 1 1-16 0 8 8 0 0 1 16 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: 16px 16px;
    opacity: 0.7;
    pointer-events: none;
}

.filter-input {
    padding-left: 52px;
}

.filter-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 6px;
}

.filter-actions .text-button {
    font-size: 0.9rem;
}

@media (max-width: 640px) {
    .filter-form {
        align-items: stretch;
        padding: 16px;
    }

    .filter-field,
    .filter-field--search {
        flex: 1 1 100%;
    }

    .filter-actions {
        padding-bottom: 0;
    }
}

.visitor-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.visitor-list-count {
    font-size: 0.85rem;
    color: rgba(226, 232, 240, 0.7);
}

.visitor-table-wrapper,
.events-table-wrapper {
    overflow-x: auto;
}

.visitor-table,
.events-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

.events-table-row {
    cursor: pointer;
    transition: background 0.2s ease;
}

.events-table-row:hover,
.events-table-row:focus-visible {
    background: rgba(148, 198, 255, 0.08);
    outline: none;
}

.visitor-table th,
.visitor-table td,
.events-table th,
.events-table td {
    text-align: left;
    padding: 12px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.95rem;
}

.visitor-table th,
.events-table th {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(226, 232, 240, 0.6);
}

.visitor-ip {
    font-family: 'SFMono-Regular', ui-monospace, SFMono, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.92rem;
}

.visitor-country-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(99, 102, 241, 0.18);
    color: #c7d2fe;
    font-size: 0.85rem;
}

.visitor-identity {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 140px;
}

.visitor-identity-line {
    font-weight: 600;
    color: rgba(226, 232, 240, 0.9);
    font-size: 0.95rem;
    letter-spacing: 0.02em;
}

.visitor-identity-subline {
    font-size: 0.82rem;
    color: rgba(226, 232, 240, 0.6);
}

.visitor-landing {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-width: 320px;
}

.visitor-landing-secondary {
    font-size: 0.82rem;
    color: rgba(226, 232, 240, 0.65);
    word-break: break-all;
}

.visitor-event-count {
    font-weight: 600;
    color: rgba(226, 232, 240, 0.85);
    font-size: 0.95rem;
}

.visitor-link {
    color: var(--link);
    text-decoration: underline;
    word-break: break-all;
}

.visitor-empty {
    color: rgba(226, 232, 240, 0.6);
}

.visitor-pagination,
.events-pagination {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.visitor-pagination-info,
.events-pagination-info {
    font-size: 0.9rem;
    color: rgba(226, 232, 240, 0.7);
}

.visitor-pagination-controls,
.events-pagination-controls {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.visitor-pagination-button,
.events-pagination-button {
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid rgba(148, 198, 255, 0.35);
    color: rgba(229, 238, 255, 0.9);
    text-decoration: none;
    font-size: 0.9rem;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.visitor-pagination-button:hover,
.events-pagination-button:hover {
    background: rgba(148, 198, 255, 0.15);
    border-color: rgba(148, 198, 255, 0.6);
}

.visitor-pagination-button.is-disabled,
.events-pagination-button.is-disabled {
    opacity: 0.45;
    pointer-events: none;
}

.visitor-pagination-pages,
.events-pagination-pages {
    display: flex;
    gap: 8px;
    padding: 0;
    margin: 0;
    list-style: none;
}

.visitor-pagination-page,
.events-pagination-page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(148, 198, 255, 0.35);
    color: rgba(229, 238, 255, 0.9);
    text-decoration: none;
    font-size: 0.9rem;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.visitor-pagination-page:hover,
.events-pagination-page:hover {
    background: rgba(148, 198, 255, 0.15);
    border-color: rgba(148, 198, 255, 0.6);
}

.visitor-pagination-page.is-active,
.events-pagination-page.is-active {
    background: rgba(76, 106, 255, 0.4);
    border-color: rgba(148, 198, 255, 0.8);
    color: #f8fafc;
    cursor: default;
}

@media (max-width: 768px) {
    .visitor-table,
    .events-table {
        min-width: unset;
    }

    .visitor-table th,
    .visitor-table td,
    .events-table th,
    .events-table td {
        padding: 10px 12px;
    }

    .visitor-summary-range {
        width: 100%;
        text-align: center;
    }

    .visitor-list-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .visitor-chart-toolbar {
        align-self: stretch;
        justify-content: center;
        flex-wrap: wrap;
    }

    .visitor-landing {
        max-width: none;
    }
}

@media (max-width: 900px) {
    .analytics-chart,
    .visitor-chart {
        min-height: 220px;
    }

    .analytics-empty-card {
        flex-direction: column;
        align-items: stretch;
    }

    .analytics-empty-icon {
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 768px) {
    .top-bar {
        padding: 18px 24px;
    }

    .menu-toggle {
        display: flex;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        right: 24px;
        margin-top: 12px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        background: var(--surface);
        border: 1px solid var(--border);
        border-radius: 16px;
        padding: 16px;
        box-shadow: var(--shadow);
        min-width: 180px;
    }

    .nav-links.is-open {
        display: flex;
    }

    .nav-links a {
        margin: 0;
        padding: 10px 0;
    }

    .nav-links a + a {
        border-top: 1px solid rgba(255, 255, 255, 0.08);
    }

    .nav-links .sign-in {
        margin-top: 12px;
    }

    .hero {
        padding: 48px 24px;
    }

    .content {
        padding: 0 20px 60px;
    }

    .site-footer {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
}
