:root {
    --bg: #f5f6fa;
    --surface: #ffffff;
    --surface-soft: #f8f8fc;
    --text: #171527;
    --muted: #747186;
    --border: #e8e6ef;
    --purple: #7258e8;
    --purple-dark: #563ccd;
    --purple-soft: #eeeafd;
    --green: #20a779;
    --amber: #e6a229;
    --red: #dc5d69;
    --blue: #4e85e8;
    --sidebar: #171428;
    --shadow: 0 18px 45px rgba(28, 22, 58, .08);
    --radius: 18px;
}

* { box-sizing: border-box; }

html { min-height: 100%; }

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    background: var(--bg);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    -webkit-font-smoothing: antialiased;
}

.public-site { display: grid; place-items: center; padding: 24px; background: #f4f2fa; }
.public-shell { width: min(100%, 520px); }
.public-message { display: flex; min-height: 330px; flex-direction: column; align-items: center; justify-content: center; padding: 42px 28px; background: white; border: 1px solid var(--border); border-radius: 22px; box-shadow: var(--shadow); text-align: center; }
.public-message .brand-mark { margin-bottom: 25px; }
.public-message h1 { margin-top: 8px; font-size: 27px; }
.public-message p { max-width: 380px; color: var(--muted); font-size: 13px; line-height: 1.6; margin: 11px 0 0; }
.public-message small { color: #9a96a7; font-size: 10px; margin-top: 22px; }

button, input, select, textarea { font: inherit; }
a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }

.auth-page {
    position: relative;
    display: grid;
    place-items: center;
    overflow-x: hidden;
    padding: 42px 20px;
    background: #f4f2fa;
}

.auth-page::before {
    position: fixed;
    inset: 0;
    content: "";
    opacity: .32;
    pointer-events: none;
    background-image: radial-gradient(#8d80c2 0.65px, transparent 0.65px);
    background-size: 18px 18px;
}

.ambient {
    position: fixed;
    width: 430px;
    height: 430px;
    border-radius: 50%;
    filter: blur(2px);
    opacity: .24;
    pointer-events: none;
}

.ambient-one { left: -210px; top: -170px; background: radial-gradient(circle, #9d88ff, transparent 68%); }
.ambient-two { right: -200px; bottom: -180px; background: radial-gradient(circle, #65c9d0, transparent 68%); }
.auth-shell { position: relative; width: min(100%, 1060px); z-index: 1; }

.auth-card,
.install-card {
    background: rgba(255, 255, 255, .96);
    border: 1px solid rgba(225, 221, 238, .95);
    box-shadow: 0 28px 80px rgba(49, 37, 91, .13);
    border-radius: 24px;
}

.auth-card-login { width: min(100%, 470px); margin: auto; padding: 40px 44px 34px; }
.auth-brand { display: flex; align-items: center; gap: 13px; }
.auth-brand > div, .sidebar-brand > span { display: flex; flex-direction: column; }
.auth-brand strong, .sidebar-brand strong { font: 800 21px/1 ui-sans-serif, system-ui, sans-serif; letter-spacing: -.04em; }
.auth-brand small, .sidebar-brand small { color: var(--muted); font-size: 11px; letter-spacing: .14em; margin-top: 4px; text-transform: uppercase; }

.brand-mark {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
}

.brand-mark i { position: absolute; display: block; border: 3px solid var(--purple); border-radius: 7px; transform: rotate(45deg); }
.brand-mark i:nth-child(1) { inset: 1px 15px 15px 1px; }
.brand-mark i:nth-child(2) { inset: 15px 1px 1px 15px; }
.brand-mark i:nth-child(3) { width: 11px; height: 11px; left: 11px; top: 11px; background: var(--purple); border: 0; border-radius: 3px; }
.brand-mark-large { width: 42px; height: 42px; transform: scale(1.16); transform-origin: left center; }

.auth-heading { margin: 43px 0 29px; }
.eyebrow { display: block; color: var(--purple); font-size: 11px; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; }
h1, h2, h3 { margin: 0; font-family: ui-sans-serif, system-ui, sans-serif; letter-spacing: -.035em; }
.auth-heading h1, .install-grid h1 { margin-top: 9px; font-size: clamp(29px, 5vw, 36px); line-height: 1.15; }
.auth-heading p, .lead { color: var(--muted); line-height: 1.65; margin: 12px 0 0; }

.form-stack { display: grid; gap: 19px; }
.form-field { display: grid; gap: 8px; color: #3e3a50; font-size: 13px; font-weight: 600; }
.form-field > span:first-child { display: flex; align-items: center; justify-content: space-between; }
.form-field > span small { color: #9895a5; font-weight: 400; }
.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    min-height: 49px;
    color: var(--text);
    background: #fbfafd;
    border: 1px solid #dedbe8;
    border-radius: 11px;
    outline: none;
    padding: 0 15px;
    transition: border-color .2s, box-shadow .2s, background .2s;
}
.form-field textarea { min-height: 120px; padding-top: 13px; line-height: 1.55; resize: vertical; }
.form-field select { appearance: none; padding-right: 38px; background-image: linear-gradient(45deg, transparent 50%, #8b8798 50%), linear-gradient(135deg, #8b8798 50%, transparent 50%); background-position: calc(100% - 18px) 21px, calc(100% - 13px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus { background-color: #fff; border-color: #8b76eb; box-shadow: 0 0 0 4px rgba(114, 88, 232, .11); }
.form-field input.invalid, .form-field select.invalid, .form-field textarea.invalid { border-color: var(--red); }
.form-field input:disabled, .form-field select:disabled { color: #aaa6b6; cursor: not-allowed; background-color: #f1f0f4; }
.field-error { color: var(--red); font-weight: 500; }
.password-control { position: relative; display: block !important; }
.password-control input { padding-right: 48px; }
.password-control button { position: absolute; top: 0; right: 3px; width: 44px; height: 49px; color: #8d899c; background: none; border: 0; cursor: pointer; }

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 44px;
    padding: 0 18px;
    border: 0;
    border-radius: 11px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: transform .18s, box-shadow .18s, background .18s;
}
.button:hover { transform: translateY(-1px); }
.button:disabled { opacity: .48; transform: none; cursor: not-allowed; }
.button-primary { color: white; background: linear-gradient(135deg, #7a61ec, #6546dc); box-shadow: 0 10px 24px rgba(102, 71, 220, .22); }
.button-primary:hover { background: linear-gradient(135deg, #6c52e0, #5839c9); box-shadow: 0 13px 28px rgba(102, 71, 220, .28); }
.button-secondary { color: #454154; background: #f5f3f8; border: 1px solid #e1deea; box-shadow: none; }
.button-secondary:hover { background: #eeebf4; }
.button-danger { color: white; background: var(--red); box-shadow: none; }
.button-danger:hover { background: #c84d59; }
.button-full { width: 100%; min-height: 51px; margin-top: 3px; }
.button span { font-size: 18px; line-height: 1; }
.auth-footnote, .form-note { display: block; color: #9692a3; font-size: 11px; text-align: center; margin: 24px 0 0; }

.alert { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 13px 15px; border: 1px solid; border-radius: 11px; font-size: 13px; margin-bottom: 18px; }
.alert-success { color: #167657; background: #ecfaf5; border-color: #c7eddf; }
.alert-error { color: #a83f4b; background: #fff1f2; border-color: #f5ced2; }
.alert-info { color: #365f9b; background: #edf4ff; border-color: #cfdef4; }
.alert button { color: currentColor; background: none; border: 0; font-size: 20px; cursor: pointer; }

.install-card { padding: 34px; }
.install-header { display: flex; align-items: center; justify-content: space-between; padding-bottom: 28px; border-bottom: 1px solid var(--border); }
.version-pill { color: var(--purple-dark); background: var(--purple-soft); border-radius: 99px; padding: 7px 11px; font-size: 11px; font-weight: 700; }
.install-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 70px; padding: 46px 20px 18px; }
.requirements-list { display: grid; margin-top: 30px; border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.requirement-row { display: flex; justify-content: space-between; gap: 20px; padding: 12px 15px; background: #fff; border-bottom: 1px solid var(--border); font-size: 12px; }
.requirement-row:last-child { border: 0; }
.requirement-row strong { font-size: 11px; white-space: nowrap; }
.check-ok { color: var(--green); }
.check-error { color: var(--red); }
.install-form-panel { padding: 28px; background: var(--surface-soft); border: 1px solid var(--border); border-radius: 18px; }
.install-form-panel h2 { font-size: 21px; }
.install-form-panel > p { color: var(--muted); font-size: 13px; margin: 6px 0 22px; }

.app-shell { display: flex; min-height: 100vh; }
.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 30;
    display: flex;
    flex-direction: column;
    width: 255px;
    color: #cbc8da;
    background: var(--sidebar);
    border-right: 1px solid rgba(255,255,255,.04);
}
.sidebar-brand { display: flex; align-items: center; gap: 12px; min-height: 85px; padding: 0 24px; color: white; border-bottom: 1px solid rgba(255,255,255,.07); }
.sidebar-brand small { color: #817d94; }
.sidebar-brand .brand-mark { transform: scale(.86); transform-origin: left center; }
.sidebar-nav { flex: 1; overflow-y: auto; padding: 22px 14px; }
.nav-label { display: block; color: #6f6a80; font-size: 9px; font-weight: 700; letter-spacing: .16em; margin: 20px 12px 8px; text-transform: uppercase; }
.nav-label:first-child { margin-top: 0; }
.nav-item { display: flex; align-items: center; gap: 12px; min-height: 43px; padding: 0 12px; margin: 3px 0; border-radius: 9px; font-size: 13px; transition: background .18s, color .18s; }
.nav-item:hover { color: white; background: rgba(255,255,255,.055); }
.nav-item.active { color: white; background: linear-gradient(90deg, rgba(117, 88, 232, .26), rgba(117, 88, 232, .08)); box-shadow: inset 3px 0 #8067ea; }
.nav-icon { display: grid; place-items: center; width: 23px; color: #918ba8; font-size: 17px; }
.nav-item.active .nav-icon { color: #a996ff; }
.sidebar-footer { display: flex; align-items: center; gap: 10px; min-height: 69px; padding: 0 24px; border-top: 1px solid rgba(255,255,255,.07); }
.sidebar-footer > span:last-child { display: flex; flex-direction: column; }
.sidebar-footer strong { color: #c4c0d1; font-size: 10px; font-weight: 600; }
.sidebar-footer small { color: #6f6a80; font-size: 9px; margin-top: 3px; }
.status-dot { width: 7px; height: 7px; background: #3fc993; border-radius: 50%; box-shadow: 0 0 0 4px rgba(63,201,147,.1); }
.main-area { width: calc(100% - 255px); min-height: 100vh; margin-left: 255px; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; min-height: 72px; padding: 0 30px; background: rgba(255,255,255,.92); border-bottom: 1px solid var(--border); backdrop-filter: blur(16px); }
.topbar-title { display: flex; flex-direction: column; }
.topbar-title span { color: #9a97a7; font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }
.topbar-title strong { font: 700 15px/1.4 ui-sans-serif, system-ui, sans-serif; }
.topbar-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.user-avatar { display: grid; place-items: center; width: 34px; height: 34px; color: var(--purple-dark); background: var(--purple-soft); border-radius: 10px; font-size: 12px; font-weight: 800; }
.user-meta { display: flex; flex-direction: column; min-width: 110px; }
.user-meta strong { font-size: 11px; }
.user-meta small { color: var(--muted); font-size: 9px; margin-top: 2px; }
.icon-button { display: grid; place-items: center; color: #787485; background: transparent; border: 0; cursor: pointer; }
.logout-button { width: 33px; height: 33px; background: #f6f5f8; border-radius: 9px; font-size: 18px; }
.menu-toggle, .sidebar-close { display: none; }
.content-area { max-width: 1480px; margin: auto; padding: 34px 34px 60px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 27px; }
.page-heading h1 { margin-top: 5px; font-size: 29px; }
.page-heading p { color: var(--muted); font-size: 13px; margin: 7px 0 0; }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 17px; }
.metric-card { position: relative; display: grid; grid-template-columns: 46px 1fr; align-items: center; min-height: 135px; padding: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 5px 20px rgba(27,20,56,.035); overflow: hidden; }
.metric-card::after { position: absolute; top: -30px; right: -25px; width: 85px; height: 85px; content: ""; background: currentColor; border-radius: 50%; opacity: .045; }
.metric-icon { display: grid; place-items: center; width: 38px; height: 38px; color: currentColor; background: color-mix(in srgb, currentColor 10%, white); border-radius: 10px; font-size: 18px; }
.metric-card > div { display: flex; flex-direction: column; }
.metric-card small { color: var(--muted); font-size: 11px; }
.metric-card strong { color: var(--text); font: 700 27px/1.25 ui-sans-serif, system-ui, sans-serif; margin-top: 3px; }
.metric-trend { grid-column: 2; color: #9995a5; font-size: 9px; margin-top: -15px; }
.metric-trend.positive { color: var(--green); }
.accent-purple { color: var(--purple); }
.accent-amber { color: var(--amber); }
.accent-blue { color: var(--blue); }
.accent-green { color: var(--green); }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 17px; margin-top: 17px; }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 5px 20px rgba(27,20,56,.035); }
.panel-header { display: flex; align-items: center; justify-content: space-between; min-height: 77px; padding: 18px 21px; border-bottom: 1px solid var(--border); }
.panel-header h2 { font-size: 15px; }
.panel-header p { color: var(--muted); font-size: 10px; margin: 4px 0 0; }
.panel-header > a { color: var(--purple); font-size: 10px; font-weight: 700; }
.resource-list { padding: 5px 20px; }
.resource-list a { display: grid; grid-template-columns: 39px 1fr auto; align-items: center; gap: 12px; min-height: 67px; border-bottom: 1px solid #f0eef4; }
.resource-list a:last-child { border: 0; }
.resource-list a > span:nth-child(2) { display: flex; flex-direction: column; }
.resource-list strong { font-size: 11px; }
.resource-list small { color: var(--muted); font-size: 9px; margin-top: 3px; }
.resource-list b { font: 700 16px ui-sans-serif, system-ui, sans-serif; }
.resource-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; }
.resource-icon.purple { color: var(--purple); background: var(--purple-soft); }
.resource-icon.blue { color: var(--blue); background: #edf4ff; }
.resource-icon.green { color: var(--green); background: #e9f9f3; }
.ssl-summary { display: flex; align-items: center; gap: 28px; min-height: 207px; padding: 25px; }
.ssl-ring { --percentage: calc(var(--value) * 1%); position: relative; display: grid; place-items: center; width: 112px; height: 112px; flex: 0 0 auto; background: conic-gradient(var(--green) var(--percentage), #eeedf2 0); border-radius: 50%; }
.ssl-ring::after { position: absolute; inset: 10px; content: ""; background: white; border-radius: 50%; }
.ssl-ring span { z-index: 1; display: flex; flex-direction: column; align-items: center; }
.ssl-ring strong { font: 700 21px ui-sans-serif, system-ui, sans-serif; }
.ssl-ring small { color: var(--muted); font-size: 9px; }
.ssl-legend { display: grid; flex: 1; gap: 13px; }
.ssl-legend > div { display: grid; grid-template-columns: 8px 1fr auto; align-items: center; gap: 8px; font-size: 10px; }
.ssl-legend strong { font-size: 11px; }
.dot { display: block; width: 7px; height: 7px; border-radius: 50%; }
.dot.green { background: var(--green); }.dot.amber { background: var(--amber); }.dot.red { background: var(--red); }

.getting-started { margin-top: 17px; }
.steps-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 20px; }
.steps-grid a { position: relative; display: flex; flex-direction: column; min-height: 110px; padding: 8px 20px 8px 49px; border-right: 1px solid var(--border); }
.steps-grid a:last-child { border: 0; }
.steps-grid a > span { position: absolute; left: 10px; top: 7px; display: grid; place-items: center; width: 27px; height: 27px; color: var(--purple); background: var(--purple-soft); border-radius: 8px; font-size: 10px; font-weight: 800; }
.steps-grid strong { font-size: 11px; }
.steps-grid small { color: var(--muted); font-size: 9px; line-height: 1.55; margin-top: 7px; }
.error-page { display: grid; place-items: center; min-height: 60vh; text-align: center; }
.error-page p, .error-card p { color: var(--muted); }
.error-code { color: var(--purple); font: 800 64px/1 ui-sans-serif, system-ui, sans-serif; opacity: .25; }
.error-card { width: min(100%, 470px); margin: auto; padding: 45px; text-align: center; }
.error-card .button { margin-top: 12px; }
.module-placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 410px; padding: 50px 25px; text-align: center; }
.module-placeholder .placeholder-icon { display: grid; place-items: center; width: 68px; height: 68px; color: var(--purple); background: var(--purple-soft); border-radius: 19px; font-size: 30px; margin-bottom: 23px; }
.module-placeholder h2 { font-size: 21px; }
.module-placeholder p { max-width: 520px; color: var(--muted); font-size: 13px; line-height: 1.65; margin: 10px 0 23px; }
.data-panel { overflow: hidden; }
.table-toolbar { display: flex; align-items: end; gap: 12px; padding: 18px 20px; border-bottom: 1px solid var(--border); }
.search-box { position: relative; flex: 1; min-width: 230px; }
.search-box > span { position: absolute; left: 14px; top: 10px; color: #8f8b9c; font-size: 19px; }
.search-box input { width: 100%; height: 42px; padding: 0 14px 0 42px; color: var(--text); background: #faf9fc; border: 1px solid #e0dde8; border-radius: 10px; outline: 0; font-size: 12px; }
.search-box input:focus { background: white; border-color: #8b76eb; box-shadow: 0 0 0 3px rgba(114,88,232,.1); }
.compact-select { display: grid; gap: 5px; color: var(--muted); font-size: 9px; }
.compact-select select { min-width: 125px; height: 42px; color: #4c485b; background: #faf9fc; border: 1px solid #e0dde8; border-radius: 10px; padding: 0 31px 0 11px; outline: none; }
.compact-select-small select { min-width: 76px; }
.clear-filter { align-self: center; color: var(--purple); font-size: 10px; font-weight: 700; }
.table-scroll { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; white-space: nowrap; }
.data-table th { height: 45px; color: #8d8999; background: #faf9fc; border-bottom: 1px solid var(--border); padding: 0 16px; font-size: 9px; font-weight: 700; letter-spacing: .04em; text-align: left; text-transform: uppercase; }
.data-table th a { display: inline-flex; align-items: center; gap: 5px; }
.data-table th a span { color: #b5b1bf; font-size: 12px; }
.data-table td { height: 68px; padding: 9px 16px; border-bottom: 1px solid #f0eef4; font-size: 11px; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: #fcfbfe; }
.data-table .row-muted { background: #faf9fb; }
.data-table .row-muted .user-cell, .data-table .row-muted .date-cell { opacity: .66; }
.actions-column { text-align: right !important; }
.user-cell { display: flex; align-items: center; gap: 11px; }
.user-cell > span:last-child { display: flex; flex-direction: column; }
.user-cell strong { color: #312d40; font-size: 11px; }
.user-cell small { color: var(--muted); font-size: 9px; margin-top: 3px; }
.table-avatar { display: grid; place-items: center; width: 35px; height: 35px; color: var(--purple-dark); background: var(--purple-soft); border-radius: 10px; font-size: 11px; font-weight: 800; }
.role-badge, .status-badge { display: inline-flex; align-items: center; border-radius: 99px; font-size: 9px; font-weight: 700; }
.role-badge { color: #625d70; background: #f0eef4; padding: 6px 9px; }
.role-administrator { color: #6247cf; background: #eeeafd; }
.role-operator { color: #376dad; background: #eaf3ff; }
.role-consultant { color: #6d6878; background: #f1f0f3; }
.status-badge { gap: 6px; padding: 5px 8px; }
.status-badge i { width: 6px; height: 6px; border-radius: 50%; }
.status-active { color: #167656; background: #eaf8f3; }.status-active i { background: var(--green); }
.status-suspended { color: #a66c14; background: #fff6e5; }.status-suspended i { background: var(--amber); }
.date-cell { color: #6f6b7d; font-size: 10px; }
.table-actions { display: flex; align-items: center; justify-content: flex-end; gap: 5px; }
.table-actions form { margin: 0; }
.table-actions a, .table-actions button { display: grid; place-items: center; width: 30px; height: 30px; color: #6f6a7f; background: #f6f4f8; border: 1px solid #ebe8f0; border-radius: 8px; cursor: pointer; font-size: 13px; }
.table-actions a:hover, .table-actions button:hover { color: var(--purple); background: var(--purple-soft); }
.table-actions .danger:hover { color: var(--red); background: #fff0f1; border-color: #f5d5d8; }
.table-footer { display: flex; align-items: center; justify-content: space-between; min-height: 58px; padding: 10px 20px; color: var(--muted); background: #fcfbfd; border-top: 1px solid var(--border); font-size: 10px; }
.pagination { display: flex; align-items: center; gap: 10px; }
.pagination a { display: grid; place-items: center; width: 29px; height: 29px; color: var(--purple); background: white; border: 1px solid #dfdce8; border-radius: 8px; font-size: 17px; }
.empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 390px; padding: 45px 20px; text-align: center; }
.empty-state > span { display: grid; place-items: center; width: 62px; height: 62px; color: var(--purple); background: var(--purple-soft); border-radius: 18px; font-size: 27px; }
.empty-state h2 { font-size: 18px; margin-top: 19px; }
.empty-state p { max-width: 430px; color: var(--muted); font-size: 12px; line-height: 1.6; margin: 8px 0 20px; }
.page-heading-back { align-items: flex-start; }
.back-link { display: inline-block; color: var(--muted); font-size: 10px; margin-bottom: 22px; }
.user-form { display: grid; gap: 17px; }
.form-section { overflow: hidden; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 19px; padding: 24px; }
.form-field-wide { grid-column: 1 / -1; }
.inline-note { color: #776da1; background: #f4f1ff; border: 1px solid #e5defd; border-radius: 10px; padding: 12px 14px; font-size: 11px; margin: 0; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; padding: 3px 0 20px; }
.button-test { color: #176f57; background: #eaf9f3; border: 1px solid #ccecdf; box-shadow: none; }
.button-test:hover { background: #dff5ed; }
.storage-page-heading { align-items: flex-end; }
.storage-cell { display: flex; align-items: center; gap: 11px; max-width: 310px; }
.storage-cell > span:last-child, .bucket-cell { display: flex; min-width: 0; flex-direction: column; }
.storage-cell strong { display: flex; align-items: center; gap: 7px; font-size: 11px; }
.storage-cell strong em { color: #644bd0; background: #eeeafd; border-radius: 99px; padding: 3px 6px; font-size: 8px; font-style: normal; text-transform: uppercase; }
.storage-cell small { max-width: 240px; color: var(--muted); font-size: 9px; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; }
.provider-badge { display: inline-flex; max-width: 180px; color: #4e647f; background: #eef4fa; border-radius: 99px; padding: 6px 9px; font-size: 9px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.provider-amazon { color: #85570e; background: #fff3dc; }
.provider-cloudflare_r2 { color: #a04d1e; background: #fff0e8; }
.provider-wasabi { color: #276d52; background: #eaf8f2; }
.provider-minio { color: #9e3445; background: #ffedf0; }
.provider-custom_path, .provider-custom_virtual { color: #6349cf; background: #eeeafd; }
.bucket-cell strong { font-size: 10px; }.bucket-cell small { color: var(--muted); font-size: 9px; margin-top: 3px; }
.masked-key { color: #6c6879; background: #f5f3f7; border-radius: 6px; padding: 5px 7px; font: 9px ui-monospace, SFMono-Regular, Menlo, monospace; }
.provider-guidance { display: flex; align-items: flex-start; gap: 10px; color: #5e5874; background: #f7f5fc; border: 1px solid #e8e3f5; border-radius: 11px; padding: 13px 15px; font-size: 11px; line-height: 1.55; }
.provider-guidance::before { content: "i"; display: grid; place-items: center; width: 19px; height: 19px; flex: 0 0 auto; color: white; background: var(--purple); border-radius: 50%; font-size: 10px; font-weight: 800; }
.credential-section { border-color: #ded7f8; }
.security-pill { color: #2c745e; background: #e9f8f2; border-radius: 99px; padding: 6px 9px; font-size: 8px; font-weight: 700; text-transform: uppercase; }
.field-help { color: #918d9e; font-size: 9px; font-weight: 400; }
.storage-options-grid { align-items: center; }
.switch-card { position: relative; display: flex; align-items: center; gap: 13px; min-height: 72px; padding: 14px; background: #faf9fc; border: 1px solid #e5e2eb; border-radius: 12px; cursor: pointer; }
.switch-card > input[type="checkbox"] { position: absolute; opacity: 0; pointer-events: none; }
.switch-control { position: relative; width: 38px; height: 22px; flex: 0 0 auto; background: #c8c4d1; border-radius: 99px; transition: .2s; }
.switch-control i { position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; background: white; border-radius: 50%; box-shadow: 0 2px 5px rgba(0,0,0,.15); transition: .2s; }
.switch-card > input:checked + input + .switch-control,
.switch-card > input:checked + .switch-control { background: var(--purple); }
.switch-card > input:checked + input + .switch-control i,
.switch-card > input:checked + .switch-control i { transform: translateX(16px); }
.switch-card > span:last-child { display: flex; flex-direction: column; }
.switch-card strong { font-size: 11px; }.switch-card small { color: var(--muted); font-size: 9px; line-height: 1.4; margin-top: 3px; }
.switch-card-locked { cursor: not-allowed; opacity: .8; }
.domain-cell { display: flex; align-items: center; gap: 11px; max-width: 360px; }
.domain-cell > span:last-child { display: flex; min-width: 0; flex-direction: column; }
.domain-cell strong { color: #312d40; font-size: 11px; }
.domain-cell small { max-width: 285px; color: var(--muted); font-size: 9px; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; }
.hostname-link { color: var(--purple-dark); font-weight: 600; }.hostname-link:hover { text-decoration: underline; }
.base-path-cell { color: #5f5876; background: #f3f1f7; border-radius: 6px; padding: 5px 7px; font-size: 9px; }
.ssl-badge { display: inline-flex; align-items: center; gap: 6px; border-radius: 99px; padding: 6px 9px; font-size: 9px; font-weight: 700; }
.ssl-badge i { width: 6px; height: 6px; border-radius: 50%; }
.ssl-valid { color: #167656; background: #eaf8f3; }.ssl-valid i { background: var(--green); }
.ssl-expiring { color: #9b6614; background: #fff5df; }.ssl-expiring i { background: var(--amber); }
.ssl-expired, .ssl-invalid, .ssl-error { color: #a33c48; background: #fff0f1; }.ssl-expired i, .ssl-invalid i, .ssl-error i { background: var(--red); }
.ssl-unknown { color: #6d6878; background: #f1f0f3; }.ssl-unknown i { background: #a7a2b1; }
.experience-count { display: inline-grid; place-items: center; min-width: 29px; height: 29px; color: #5f5876; background: #f3f1f7; border-radius: 8px; font-size: 10px; }
.input-prefix { display: flex !important; align-items: stretch !important; min-height: 49px; padding: 0 !important; background: #fbfafd; border: 1px solid #dedbe8; border-radius: 11px; overflow: hidden; }
.input-prefix:focus-within { background: white; border-color: #8b76eb; box-shadow: 0 0 0 4px rgba(114,88,232,.11); }
.input-prefix b { display: flex; align-items: center; padding: 0 0 0 14px; color: #8c879a; font-size: 12px; font-weight: 500; }
.input-prefix input { min-width: 0; border: 0; background: transparent; box-shadow: none !important; padding-left: 3px; }
.input-prefix:has(input.invalid) { border-color: var(--red); }
.url-preview { display: flex; align-items: center; justify-content: space-between; gap: 15px; color: #655e78; background: #f7f5fc; border: 1px solid #e6e1f4; border-radius: 11px; padding: 13px 15px; font-size: 10px; }
.url-preview strong { max-width: 75%; color: var(--purple-dark); font: 600 11px ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; text-align: right; }
.change-warning { display: grid; grid-template-columns: 36px 1fr auto; align-items: center; gap: 14px; color: #744d13; background: #fff8e9; border: 1px solid #f0dcae; border-radius: 14px; padding: 17px 19px; }
.change-warning > span { display: grid; place-items: center; width: 34px; height: 34px; color: white; background: var(--amber); border-radius: 10px; font-weight: 800; }
.change-warning strong { font-size: 12px; }.change-warning p { font-size: 10px; line-height: 1.5; margin: 4px 0 0; }
.change-warning label { display: flex; align-items: center; gap: 8px; max-width: 265px; font-size: 10px; line-height: 1.4; cursor: pointer; }
.domain-show-heading { align-items: flex-end; }
.public-url { color: var(--purple); font-weight: 600; }
.heading-actions { display: flex; align-items: center; gap: 9px; }.heading-actions form { margin: 0; }
.domain-detail-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(300px, .85fr); gap: 17px; }
.detail-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 0; padding: 9px 21px 19px; }
.detail-list div { padding: 14px 0; border-bottom: 1px solid #f0eef4; }
.detail-list div:nth-last-child(-n+2) { border-bottom: 0; }
.detail-list dt { color: var(--muted); font-size: 9px; margin-bottom: 6px; }
.detail-list dd { margin: 0; font-size: 11px; font-weight: 600; overflow-wrap: anywhere; }
.detail-list code { color: #5f5876; background: #f3f1f7; border-radius: 6px; padding: 4px 6px; font-size: 10px; }
.ssl-detail-body { display: grid; gap: 12px; padding: 23px; }
.ssl-detail-body > .ssl-badge { justify-self: start; font-size: 10px; padding: 8px 11px; }
.ssl-detail-body .detail-list { grid-template-columns: 1fr; padding: 0; }
.ssl-detail-body .detail-list div:last-child { border-bottom: 0; }
.ssl-detail-body > p { color: var(--muted); font-size: 10px; line-height: 1.55; margin: 0; }
.domain-notes, .linked-experiences { margin-top: 17px; overflow: hidden; }
.domain-notes > p { color: #5f5a6e; font-size: 11px; line-height: 1.65; margin: 0; padding: 21px; }
.compact-empty { color: var(--muted); padding: 34px 21px; font-size: 11px; text-align: center; }
.danger-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 17px; }.danger-actions form { margin: 0; }
.sidebar-overlay { display: none; }

@media (max-width: 1080px) {
    .metric-grid { grid-template-columns: repeat(2, 1fr); }
    .steps-grid { grid-template-columns: repeat(2, 1fr); gap: 15px 0; }
    .steps-grid a:nth-child(2) { border-right: 0; }
}

@media (max-width: 820px) {
    .sidebar { transform: translateX(-100%); transition: transform .25s ease; }
    body.sidebar-open .sidebar { transform: translateX(0); }
    .sidebar-overlay { position: fixed; inset: 0; z-index: 25; display: block; visibility: hidden; opacity: 0; background: rgba(15,12,27,.52); transition: .25s; }
    body.sidebar-open .sidebar-overlay { visibility: visible; opacity: 1; }
    .sidebar-close { display: grid; margin-left: auto; color: #a5a0b6; font-size: 25px; }
    .main-area { width: 100%; margin: 0; }
    .menu-toggle { display: grid; width: 37px; height: 37px; margin-right: 12px; background: #f3f1f8; border-radius: 9px; }
    .dashboard-grid { grid-template-columns: 1fr; }
    .install-grid { grid-template-columns: 1fr; gap: 35px; }
    .table-toolbar { align-items: stretch; flex-wrap: wrap; }
    .search-box { flex-basis: 100%; }
}

@media (max-width: 600px) {
    .auth-page { padding: 18px 12px; }
    .auth-card-login { padding: 30px 24px 27px; }
    .auth-heading { margin-top: 34px; }
    .install-card { padding: 22px 17px; }
    .install-grid { padding: 34px 0 5px; }
    .install-form-panel { padding: 22px 18px; }
    .version-pill { display: none; }
    .topbar { padding: 0 16px; }
    .user-meta { display: none; }
    .content-area { padding: 25px 15px 45px; }
    .page-heading { align-items: flex-start; flex-direction: column; }
    .page-heading .button { width: 100%; }
    .metric-grid { grid-template-columns: 1fr; }
    .metric-card { min-height: 115px; }
    .steps-grid { grid-template-columns: 1fr; }
    .steps-grid a { border-right: 0; border-bottom: 1px solid var(--border); }
    .steps-grid a:last-child { border-bottom: 0; }
    .ssl-summary { align-items: flex-start; }
    .ssl-ring { width: 92px; height: 92px; }
    .form-grid { grid-template-columns: 1fr; padding: 20px 17px; }
    .form-field-wide { grid-column: auto; }
    .form-actions { flex-direction: column-reverse; }
    .form-actions .button { width: 100%; }
    .table-footer { align-items: flex-start; flex-direction: column; gap: 10px; }
    .storage-page-heading { align-items: stretch; }
    .storage-page-heading form, .storage-page-heading .button { width: 100%; }
    .security-pill { display: none; }
    .url-preview { align-items: flex-start; flex-direction: column; }
    .url-preview strong { max-width: 100%; text-align: left; }
    .change-warning { grid-template-columns: 36px 1fr; }
    .change-warning label { grid-column: 1 / -1; max-width: none; }
    .domain-show-heading { align-items: stretch; }
    .heading-actions { align-items: stretch; flex-direction: column; }
    .heading-actions .button, .heading-actions form { width: 100%; }
    .domain-detail-grid { grid-template-columns: 1fr; }
    .detail-list { grid-template-columns: 1fr; }
    .detail-list div:nth-last-child(2) { border-bottom: 1px solid #f0eef4; }
    .danger-actions { align-items: stretch; flex-direction: column; }
    .danger-actions form, .danger-actions .button { width: 100%; }
}
