:root {
    --bg-dark: #030716;
    --bg-mid: #06122b;
    --bg-light: #0b1d44;
    --accent: #4f7dff;
    --accent-strong: #6c4bff;
    --accent-soft: #16a34a;
    --text-main: #f8fbff;
    --text-muted: rgba(248, 251, 255, 0.7);
    --glass: rgba(17, 33, 66, 0.75);
    --border: rgba(255, 255, 255, 0.15);
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    background: radial-gradient(circle at 15% 20%, rgba(73, 125, 255, 0.4), transparent 40%),
        radial-gradient(circle at 85% 0%, rgba(108, 75, 255, 0.35), transparent 45%),
        linear-gradient(180deg, #02040d 0%, #06122b 45%, #030716 100%);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
}

.dashboard-body {
    background: #f8fafc;
    color: #0f172a;
    display: block;
    min-height: 100vh;
}

.dashboard-body input[type="text"],
.dashboard-body input[type="email"],
.dashboard-body input[type="password"],
.dashboard-body input[type="tel"],
.dashboard-body input[type="url"],
.dashboard-body input[type="number"],
.dashboard-body select,
.dashboard-body textarea {
    width: 100%;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    padding: 0.65rem 0.8rem;
    background: #ffffff;
    color: #0f172a;
    font-size: 0.92rem;
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.06);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.dashboard-body input[type="text"]:focus,
.dashboard-body input[type="email"]:focus,
.dashboard-body input[type="password"]:focus,
.dashboard-body input[type="tel"]:focus,
.dashboard-body input[type="url"]:focus,
.dashboard-body input[type="number"]:focus,
.dashboard-body select:focus,
.dashboard-body textarea:focus {
    border-color: #1ABBFF;
    outline: none;
    box-shadow: 0 0 0 2px rgba(26, 187, 255, 0.15);
}

.dashboard-language {
    position: static;
}

.language-selector {
    position: fixed;
    top: 18px;
    right: 20px;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.78rem;
}

.language-selector select {
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.9);
    color: #0b132b;
}

.language-flag {
    font-size: 1rem;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.35));
}

.language-selector select option {
    color: #0b132b;
    background: #ffffff;
}

.auth-lang-toggle {
    position: fixed;
    top: 18px;
    right: 20px;
    z-index: 10;
}

.page-shell {
    width: min(100%, 1100px);
    padding: 2.5rem 1.5rem 3rem;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.auth-card {
    width: min(480px, 92vw);
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2.1rem;
    box-shadow: 0 35px 80px rgba(6, 12, 32, 0.7);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.auth-card::after {
    content: '';
    position: absolute;
    inset: -40% 20% auto auto;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(79, 125, 255, 0.5), transparent 60%);
    opacity: 0.5;
    animation: float 14s ease-in-out infinite;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 2.4rem;
    position: relative;
    z-index: 1;
}

.brand.logo-only {
    gap: 0;
}

.brand img {
    width: 42px;
    height: auto;
}

.landing-logo img,
.logo-only img {
    width: 240px;
}

.brand .title {
    font-size: 1.15rem;
    font-weight: 600;
}

.auth-title {
    margin: 0 0 0.5rem;
    font-size: clamp(1.6rem, 2.6vw, 2.1rem);
    position: relative;
    z-index: 1;
}

.auth-subtitle {
    margin: 0 0 1.5rem;
    color: var(--text-muted);
    line-height: 1.5;
    position: relative;
    z-index: 1;
}

.form-error {
    display: none;
    margin: -0.5rem 0 1.2rem;
    padding: 0.6rem 0.9rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 99, 99, 0.6);
    color: #ffd7d7;
    background: rgba(255, 99, 99, 0.12);
    font-size: 0.86rem;
}

.form-error.is-visible {
    display: block;
}

.form-error.is-success {
    border-color: rgba(34, 197, 94, 0.6);
    background: rgba(34, 197, 94, 0.12);
    color: #15803d;
    font-weight: 600;
}

.form-error.is-danger {
    border-color: rgba(239, 68, 68, 0.6);
    background: rgba(239, 68, 68, 0.12);
    color: #b91c1c;
    font-weight: 600;
}

.form-group {
    margin-bottom: 0.85rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    position: relative;
    z-index: 1;
}

label {
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.88rem;
}

.field-hint {
    margin: 0.15rem 0 0;
    color: #64748b;
    font-size: 0.78rem;
}

input,
textarea {
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(248, 251, 255, 0.9);
    padding: 0.7rem 0.9rem;
    font-size: 0.92rem;
    color: #0b132b;
}

input:focus,
textarea:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: 0 0 0 2px rgba(79, 125, 255, 0.2);
}

.button-stack {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
    margin-top: 1.4rem;
    position: relative;
    z-index: 1;
}

.btn-primary {
    border: none;
    border-radius: 8px;
    padding: 0.8rem 1rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0.01rem;
    background: linear-gradient(135deg, #1ABBFF, #1ABBFF);
    color: #fff;
    text-decoration: none;
    display: block;
    text-align: center;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 8px 16px rgba(26, 187, 255, 0.28);
}

.btn-primary.full-width {
    margin-top: 1.6rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 22px rgba(26, 187, 255, 0.36);
}

.btn-primary.full-width {
    width: 100%;
}

.btn-secondary {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0.65rem 1.2rem;
    background: #ffffff;
    color: #0f172a;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.btn-secondary:hover {
    transform: translateY(-1px);
    border-color: #cbd5f5;
    box-shadow: 0 12px 20px rgba(15, 23, 42, 0.08);
}

.icon-button-text {
    gap: 0.45rem;
    padding-left: 0.9rem;
    padding-right: 0.9rem;
}

.icon-button-text svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
}

.btn-danger {
    border: none;
    border-radius: 10px;
    padding: 0.65rem 1.2rem;
    background: #ef4444;
    color: #ffffff;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-danger:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 20px rgba(239, 68, 68, 0.25);
}

.btn-ghost {
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 8px;
    padding: 0.7rem 100px;
    text-decoration: none;
    text-align: center;
    color: var(--text-main);
    font-weight: 600;
    letter-spacing: 0.01rem;
    text-transform: none;
    background: transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-ghost.full-width {
    width: 100%;
}

.btn-ghost:hover {
    transform: translateY(-2px);
    box-shadow: none;
}

.panel-footer {
    margin-top: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.panel-footer.outside-card {
    width: min(520px, 92vw);
    margin-top: 1.2rem;
    justify-content: center;
    align-self: center;
    text-align: center;
}

.panel-footer.outside-card + .panel-footer.outside-card {
    margin-top: 1.2rem;
}

.helper-link {
    font-size: 0.9rem;
    color: #64748b;
}

.btn-ghost.helper-link {
    border: none;
    background: transparent;
    padding: 0;
}

.info-note {
    color: var(--text-muted);
    font-size: 0.82rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.info-note span {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--accent-soft);
}

.orb {
    position: fixed;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    filter: blur(30px);
    opacity: 0.45;
    z-index: 1;
    pointer-events: none;
}

.orb-one {
    top: -140px;
    right: -140px;
    background: radial-gradient(circle, rgba(79, 125, 255, 0.5), transparent 60%);
    animation: float 18s ease-in-out infinite;
}

.orb-two {
    bottom: -160px;
    left: -140px;
    background: radial-gradient(circle, rgba(108, 75, 255, 0.45), transparent 60%);
    animation: float 16s ease-in-out infinite reverse;
}

@keyframes float {
    0% {
        transform: translate3d(0, 0, 0);
    }
    50% {
        transform: translate3d(12px, -12px, 0);
    }
    100% {
        transform: translate3d(0, 6px, 0);
    }
}

@media (max-width: 640px) {
    .auth-card {
        padding: 2rem;
    }

    .panel-footer {
        flex-direction: column;
        align-items: flex-start;
    }

    .page-shell {
        padding-top: 5.5rem;
    }
}

/* Dashboard layout */
.app-shell {
    min-height: 100vh;
    background: #f8fafc;
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 260px;
    height: 100vh;
    background: #ffffff;
    border-right: 1px solid #e2e8f0;
    padding: 1.2rem 1.05rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
}

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

.sidebar-link.logout {
    color: #ef4444;
}

.sidebar-link.logout .icon {
    background: rgba(239, 68, 68, 0.12);
}

.sidebar-link.logout svg {
    stroke: #ef4444;
}

.sidebar-header img {
    width: 100%;
    max-width: 200px;
    height: auto;
}

.sidebar-section {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.sidebar-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 0.4rem 0 0.1rem;
}

.sidebar-label {
    font-size: 0.75rem;
    letter-spacing: 0.12rem;
    text-transform: uppercase;
    color: #94a3b8;
    margin: 0 0 0.2rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.55rem 0.7rem;
    border-radius: 12px;
    color: #0f172a;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
}

.sidebar-link .icon {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.sidebar-link svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: #17C9FF;
    stroke-width: 1.8;
}

.sidebar-link.is-active {
    background: #17C9FF;
    color: #ffffff;
}

.sidebar-link.is-active svg {
    stroke: #ffffff;
}

.content {
    padding: 2.5rem 3rem;
    margin-left: 260px;
}

.app-header {
    position: sticky;
    top: 0;
    z-index: 5;
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    margin: -2.5rem -3rem 2rem;
    padding: 1rem 3rem;
}

.app-header-inner {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 1.4rem;
}

.topbar-actions-row {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.lang-toggle {
    margin-left: 0.4rem;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.lang-toggle:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

.lang-flag {
    width: 22px;
    height: 22px;
    border-radius: 4px;
    display: inline-block;
    box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.lang-flag.is-fr {
    background: linear-gradient(90deg, #1f4fd8 0 33%, #ffffff 33% 66%, #ef4444 66% 100%);
}

.lang-flag.is-us {
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='44' height='44' viewBox='0 0 44 44'><rect width='44' height='44' fill='%23b91c1c'/><g fill='%23ffffff'><rect y='4' width='44' height='4'/><rect y='12' width='44' height='4'/><rect y='20' width='44' height='4'/><rect y='28' width='44' height='4'/><rect y='36' width='44' height='4'/></g><rect width='22' height='22' fill='%231f4fd8'/><g fill='%23ffffff'><circle cx='4' cy='4' r='1.1'/><circle cx='10' cy='4' r='1.1'/><circle cx='16' cy='4' r='1.1'/><circle cx='4' cy='10' r='1.1'/><circle cx='10' cy='10' r='1.1'/><circle cx='16' cy='10' r='1.1'/><circle cx='4' cy='16' r='1.1'/><circle cx='10' cy='16' r='1.1'/><circle cx='16' cy='16' r='1.1'/></g></svg>");
    background-size: cover;
    background-position: center;
}

.user-menu {
    position: relative;
}

.user-menu-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    background: transparent;
    border: none;
    padding: 0;
    cursor: pointer;
    text-align: left;
}

.user-menu-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
    min-width: 220px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 0.5rem;
    display: none;
    flex-direction: column;
    gap: 0.25rem;
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.12);
    z-index: 10;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.user-menu.is-open .user-menu-dropdown {
    display: flex;
}

.user-menu-dropdown a,
.user-menu-dropdown button {
    border: none;
    background: transparent;
    text-decoration: none;
    color: #0f172a;
    font-weight: 600;
    font-size: 0.92rem;
    padding: 0.6rem 0.75rem;
    border-radius: 10px;
    text-align: left;
    cursor: pointer;
}

.user-menu-dropdown a:hover,
.user-menu-dropdown button:hover {
    background: #f1f5f9;
}

.profile-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(160px, 1fr));
    gap: 1rem;
}

.profile-grid {
    display: grid;
    grid-template-columns: 1.25fr 1fr;
    gap: 2rem;
}

.profile-panel {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

.presentation-panel .presentation-header {
    margin-bottom: 1.2rem;
}

.presentation-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.8rem;
}

.presentation-header h2 {
    margin: 0;
}

.editor-toolbar {
    display: inline-flex;
    gap: 0.5rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 0.35rem;
    border-radius: 10px;
}

.toolbar-btn {
    border: none;
    background: #ffffff;
    border-radius: 8px;
    padding: 0.35rem 0.6rem;
    cursor: pointer;
    font-weight: 600;
    color: #0f172a;
}

.toolbar-btn:hover {
    background: #eef2ff;
}

.presentation-form .rich-editor {
    min-height: 220px;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    font-size: 0.95rem;
    line-height: 1.6;
    color: #0f172a;
}

.presentation-form .rich-editor:focus {
    outline: none;
    border-color: #1abbff;
    box-shadow: 0 0 0 2px rgba(26, 187, 255, 0.2);
}

.presentation-form .rich-editor:empty::before {
    content: attr(data-placeholder);
    color: #94a3b8;
}

.account-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 2rem 0;
}

.account-password h2 {
    margin: 0 0 1rem;
}

@media (max-width: 720px) {
    .profile-form .form-row {
        grid-template-columns: 1fr;
    }

    .profile-grid {
        grid-template-columns: 1fr;
    }
}

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    margin-bottom: 2rem;
}

.topbar h1 {
    margin: 0 0 0.4rem;
    font-size: 1.8rem;
}

.topbar p {
    margin: 0;
    color: #64748b;
}

.topbar-user {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #17C9FF;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.user-name {
    margin: 0;
    font-weight: 600;
}

.user-role {
    font-size: 0.8rem;
    color: #94a3b8;
}

.content-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

.content-card h2 {
    margin-top: 0;
}

.stats-card {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.stats-header h2 {
    margin: 0 0 0.35rem;
}

.stats-header p {
    margin: 0;
    color: #64748b;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(180px, 1fr));
    gap: 1.2rem;
}

.stat-tile {
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 1rem 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.9rem;
    background: #ffffff;
    box-shadow: 0 12px 25px rgba(15, 23, 42, 0.04);
}

.stat-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(23, 201, 255, 0.15);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #17C9FF;
}

.stat-icon svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
}

.stat-tile p {
    margin: 0;
    color: #64748b;
    font-size: 0.85rem;
}

.stat-tile strong {
    display: block;
    margin-top: 0.2rem;
    font-size: 1.35rem;
    color: #0f172a;
}

.chart-card {
    margin-top: 1.8rem;
}

.chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
    color: #64748b;
    font-size: 0.85rem;
}

.legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    display: inline-block;
}

.legend-dot.is-views {
    background: #17C9FF;
}

.legend-dot.is-installs {
    background: #10b981;
}

.legend-dot.is-links {
    background: #6366f1;
}

.legend-dot.is-reviews {
    background: #f59e0b;
}

.chart-container {
    width: 100%;
    height: 260px;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 0.75rem 1rem;
    background: #ffffff;
}

.social-chart {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    padding: 0.5rem 0.2rem 0.2rem;
}

.social-bar {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding: 0.9rem 0.8rem;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.social-bar .bar-label {
    font-weight: 600;
    text-transform: capitalize;
    color: #0f172a;
}

.social-bar .bar-track {
    position: relative;
    height: 8px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.08);
    overflow: hidden;
}

.social-bar .bar-fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0%;
    border-radius: 999px;
}

.social-bar .bar-value {
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 600;
}

.chart-container svg {
    width: 100%;
    height: 100%;
}

.chart-range {
    margin-top: 0.7rem;
    font-size: 0.8rem;
    color: #94a3b8;
}

.appearance-grid {
    display: grid;
    grid-template-columns: minmax(340px, 1fr) minmax(320px, 420px);
    gap: 2.4rem;
    align-items: start;
}

.appearance-form {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 1.8rem;
    box-shadow: 0 18px 32px rgba(15, 23, 42, 0.08);
}

.appearance-form h2 {
    margin-top: 0;
    margin-bottom: 0.4rem;
    font-size: 1.25rem;
}

.appearance-form .muted {
    color: #64748b;
    margin: 0 0 1.4rem;
    font-size: 0.92rem;
}

.appearance-form .form-group label {
    color: #0f172a;
    font-size: 0.85rem;
}

.profile-form label {
    color: #1f2937;
}

.appearance-form input[type=\"text\"],
.appearance-form input[type=\"color\"],
.appearance-form input[type=\"file\"],
.appearance-form select,
.appearance-form textarea {
    width: 100%;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    padding: 0.65rem 0.8rem;
    background: #ffffff;
    color: #0f172a;
    font-size: 0.92rem;
    box-shadow: 0 10px 18px rgba(15, 23, 42, 0.04);
}

.appearance-form input[type=\"file\"] {
    padding: 0.55rem 0.75rem;
    background: #ffffff;
}

.appearance-form input[type=\"color\"] {
    padding: 0.2rem;
    height: 44px;
}

.appearance-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(140px, 1fr));
    gap: 1rem;
    margin-top: 0.75rem;
}

.appearance-form .form-row:first-of-type {
    margin-top: 1.2rem;
}

.appearance-form .form-group-file {
    margin-bottom: 1rem;
}

.appearance-form .file-input {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.35rem 0.5rem;
    border-radius: 12px;
    border: 1px dashed #e2e8f0;
    background: #ffffff;
    position: relative;
    min-height: 48px;
}

.appearance-form .file-input input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.appearance-form .file-btn {
    border: none;
    border-radius: 10px;
    padding: 0.5rem 0.9rem;
    background: #0f172a;
    color: #ffffff;
    font-weight: 600;
    font-size: 0.85rem;
}

.appearance-form .file-name {
    font-size: 0.85rem;
    color: #64748b;
    line-height: 1.2;
}

.appearance-form .color-input {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.appearance-form .color-input input[type="color"] {
    width: 64px;
    height: 44px;
    padding: 0.2rem;
}

.appearance-form .color-hex {
    width: 110px;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: #0f172a;
    text-align: center;
}

.appearance-preview {
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    padding: 1.6rem;
    box-shadow: 0 18px 34px rgba(15, 23, 42, 0.08);
}

.appearance-icon-preview {
    display: flex;
    justify-content: center;
    margin-bottom: 1.4rem;
}

.appearance-icon-preview img {
    width: 96px;
    height: 96px;
    border-radius: 22px;
    border: 1px solid #e2e8f0;
    object-fit: cover;
    background: #ffffff;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.14);
}

.preview-phone {
    background: #0b1229;
    border-radius: 34px;
    padding: 16px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.3);
}

.preview-screen {
    border-radius: 26px;
    overflow: hidden;
    background: var(--preview-bg);
    color: var(--preview-text);
    font-family: var(--preview-font);
    position: relative;
}

.preview-cover {
    height: 190px;
    background: #0b1229;
    background-size: cover;
    background-position: center;
    position: relative;
}

.preview-cover img,
.preview-cover-placeholder {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.preview-cover-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 0.85rem;
    background: rgba(148, 163, 184, 0.2);
}

.preview-body {
    background: #ffffff;
    padding: 1.9rem 1.5rem 2rem;
    margin-top: -70px;
    border-radius: 26px 26px 0 0;
    position: relative;
}

.preview-avatar {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: -90px auto 1.1rem;
    overflow: hidden;
}

.preview-avatar img {
    width: 88px;
    height: 88px;
    object-fit: contain;
}

.preview-logo-placeholder {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    border: 1px dashed rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    color: #64748b;
}

.preview-name {
    margin: 0 0 0.4rem;
    font-size: 1.2rem;
    font-weight: 700;
    text-align: center;
    color: var(--preview-text);
}

.preview-role {
    margin: 0 0 1.2rem;
    color: var(--preview-text);
    opacity: 0.65;
    font-size: 0.95rem;
    text-align: center;
}

.preview-info {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-bottom: 1.4rem;
}

.preview-info-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 0.8rem;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.04);
    font-size: 0.92rem;
    color: var(--preview-text);
}

.preview-info-item.is-muted {
    color: var(--preview-text);
    background: rgba(15, 23, 42, 0.03);
    opacity: 0.6;
}

.preview-info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    color: var(--preview-text);
}

.preview-info-icon svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.8;
}

.preview-actions {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.preview-btn {
    border: none;
    border-radius: 999px;
    padding: 0.7rem 1rem;
    font-weight: 600;
    background: var(--preview-button);
    color: var(--preview-button-text);
    cursor: pointer;
    font-size: 0.95rem;
}

.preview-btn.preview-btn-muted {
    background: rgba(15, 23, 42, 0.08);
    color: #0f172a;
}

@media (max-width: 960px) {
    .sidebar {
        width: 220px;
    }

    .content {
        padding: 2rem;
        margin-left: 220px;
    }

    .app-header {
        margin: -2rem -2rem 1.5rem;
        padding: 0.9rem 2rem;
    }

    .appearance-grid {
        grid-template-columns: 1fr;
    }

    .topbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .stats-grid {
        grid-template-columns: repeat(2, minmax(180px, 1fr));
    }
}

@media (max-width: 720px) {
    .sidebar {
        position: static;
        width: 100%;
        height: auto;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        border-right: none;
        border-bottom: 1px solid #e2e8f0;
    }

    .sidebar-section {
        flex-direction: row;
        align-items: center;
        gap: 0.4rem;
        flex-wrap: wrap;
        width: 100%;
    }

    .sidebar-label {
        display: none;
    }

    .sidebar-link {
        flex: 1 1 100%;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .content {
        margin-left: 0;
    }
}
.topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    justify-content: flex-end;
}

.table-search {
    position: relative;
    display: flex;
    align-items: center;
}

.table-search svg {
    position: absolute;
    left: 12px;
    width: 16px;
    height: 16px;
    fill: none;
    stroke: #94a3b8;
    stroke-width: 1.8;
}

.table-search input {
    padding: 0.55rem 0.9rem 0.55rem 2.2rem;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    font-size: 0.88rem;
    min-width: 320px;
}

.table-wrap {
    overflow-x: auto;
}

.contacts-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 880px;
}

.contacts-table th,
.contacts-table td {
    padding: 0.85rem 0.9rem;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.9rem;
    color: #0f172a;
}

.contacts-table th {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08rem;
    color: #64748b;
    background: #f8fafc;
}

.contacts-table tbody tr:hover {
    background: #f8fafc;
}

.table-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.icon-button {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #1f4fd8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.icon-button:hover {
    transform: translateY(-1px);
    background: #eef2ff;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

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

.empty-state.is-hidden {
    display: none;
}

.profile-detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.profile-detail-card h2 {
    margin-top: 0;
}

.profile-detail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.modal-warning {
    color: #334155;
    line-height: 1.5;
    margin: 0 0 1.5rem;
}

.modal-note {
    margin: 0 0 0.7rem;
    color: #64748b;
    font-size: 0.9rem;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.profile-detail-list {
    display: grid;
    gap: 1rem;
}

.profile-detail-list span {
    display: block;
    color: #64748b;
    font-size: 0.85rem;
    margin-bottom: 0.25rem;
}

.profile-detail-list strong {
    color: #0f172a;
    font-size: 1rem;
}

.qr-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
}

.qr-link {
    margin: 0.8rem 0 0;
    font-size: 0.85rem;
    color: #64748b;
    word-break: break-all;
}

.qr-card img {
    width: 220px;
    height: 220px;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    padding: 0.5rem;
}

.qr-card.is-locked img {
    filter: blur(6px);
}

.qr-overlay {
    position: absolute;
    inset: 0.5rem;
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.55);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    text-align: center;
    padding: 1rem;
}

.qr-card {
    position: relative;
}

.invoices-card .stats-header {
    margin-bottom: 1rem;
}

.invoices-table .btn-secondary {
    padding: 0.5rem 1rem;
    border-radius: 999px;
}

.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04rem;
}

.badge-subscription {
    background: rgba(59, 130, 246, 0.15);
    color: #1d4ed8;
}

.badge-nfc {
    background: rgba(16, 185, 129, 0.15);
    color: #059669;
}

.badge-paid {
    background: rgba(34, 197, 94, 0.2);
    color: #15803d;
}

.badge-pending {
    background: rgba(148, 163, 184, 0.25);
    color: #475569;
}

.badge-preparing {
    background: rgba(59, 130, 246, 0.18);
    color: #1d4ed8;
}

.badge-shipping {
    background: rgba(234, 179, 8, 0.2);
    color: #a16207;
}

.badge-delivered {
    background: rgba(16, 185, 129, 0.18);
    color: #047857;
}

.profile-item {
    cursor: pointer;
}

@media (max-width: 960px) {
    .profile-detail-grid {
        grid-template-columns: 1fr;
    }
}

.notification-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #475569;
    cursor: pointer;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.notification-btn svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
}

.notification-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

.dashboard-language {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.6rem;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.dashboard-language .language-flag {
    font-size: 0.9rem;
}

.dashboard-language select {
    border: none;
    background: transparent;
    padding: 0;
    height: 28px;
    font-size: 0.85rem;
    color: #0f172a;
}

.dashboard-language select:focus {
    outline: none;
}

/* Profiles */
.profile-card {
    max-width: none;
    width: 100%;
    background: transparent;
    border: none;
    padding: 0;
    box-shadow: none;
}

.profile-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    width: 100%;
}

.profile-panel {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

@media (max-width: 720px) {
    .profile-grid {
        grid-template-columns: 1fr;
    }
}
.profiles-card {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.socials-card {
    max-width: 900px;
}

.socials-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.links-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.drag-handle {
    font-weight: 700;
    color: #94a3b8;
    cursor: grab;
    user-select: none;
    text-align: center;
}

.social-row {
    display: grid;
    grid-template-columns: 28px 48px 1fr;
    gap: 1rem;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 0.9rem 1rem;
}

.social-row.is-filled,
.links-row.is-filled {
    background: #eef6ff;
    border-color: #cfe2ff;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.social-badge {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    background: #1f4fd8;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
}

.social-badge.instagram { background: #e1306c; }
.social-badge.facebook { background: #1877f2; }
.social-badge.x { background: #0f172a; }
.social-badge.tiktok { background: #111827; }
.social-badge.youtube { background: #ff0000; }
.social-badge.whatsapp { background: #25d366; }
.social-badge.telegram { background: #229ed9; }

.social-field label {
    color: #1f2937;
}

.social-field input {
    width: 100%;
    background: #ffffff;
    border: 1px solid #e2e8f0;
}

.links-row {
    display: grid;
    grid-template-columns: 28px repeat(2, minmax(200px, 1fr));
    gap: 1rem;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 0.9rem 1rem;
}

.links-field label {
    color: #1f2937;
}

.links-field input {
    width: 100%;
    background: #ffffff;
    border: 1px solid #e2e8f0;
}

.reviews-card {
    max-width: 720px;
}

.reviews-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contacts-card {
    max-width: none;
    width: 100%;
}

.contacts-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-item {
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 1rem 1.2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    background: #ffffff;
}

.contact-main h3 {
    margin: 0 0 0.3rem;
}

.contact-company {
    margin: 0 0 0.3rem;
    font-weight: 600;
    color: #1f2937;
}

.contact-meta {
    margin: 0 0 0.25rem;
    color: #64748b;
    font-size: 0.9rem;
}

.contact-profile {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.2rem;
    font-size: 0.85rem;
    color: #475569;
}

@media (max-width: 720px) {
    .contact-item {
        flex-direction: column;
        align-items: flex-start;
    }
    .contact-profile {
        align-items: flex-start;
    }
}
@media (max-width: 720px) {
    .social-row {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    .social-icon {
        justify-content: flex-start;
    }

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

.profiles-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.profiles-count {
    min-width: 36px;
    height: 36px;
    border-radius: 999px;
    background: #eef2ff;
    color: #1f4fd8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.profiles-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.profile-item {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1.2rem 1.4rem;
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    background: #ffffff;
}

.profile-title {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.profile-title h3 {
    margin: 0;
    font-size: 1.05rem;
}

.profile-subtitle,
.profile-contact,
.profile-date {
    margin: 0.25rem 0 0;
    color: #64748b;
    font-size: 0.9rem;
}

.profile-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.6rem;
    min-width: 180px;
}

.profile-action-text {
    font-weight: 600;
    color: #16a34a;
}

.status-badge {
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04rem;
}

.status-active {
    background: rgba(34, 197, 94, 0.16);
    color: #16a34a;
}

.status-pending {
    background: rgba(234, 179, 8, 0.18);
    color: #b45309;
}

.status-suspended {
    background: rgba(239, 68, 68, 0.16);
    color: #ef4444;
}

.empty-state {
    margin: 0;
    color: #64748b;
    text-align: center;
}

.alert {
    padding: 0.9rem 1rem;
    border-radius: 14px;
    margin-bottom: 1rem;
    font-weight: 500;
}

.alert.success {
    background: rgba(34, 197, 94, 0.14);
    color: #15803d;
}

.alert.error {
    background: rgba(239, 68, 68, 0.12);
    color: #b91c1c;
}

.text-muted {
    color: #94a3b8;
    font-size: 0.85rem;
}

/* Payment */
.payment-card {
    max-width: 560px;
}

.payment-profile {
    margin: 0 0 1rem;
    font-weight: 600;
}

.payment-note {
    color: #64748b;
}

.payment-actions {
    margin-top: 1.6rem;
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

/* Modal */
.modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 50;
}

.modal.is-visible {
    display: flex;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
}

.modal-card {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    padding: 1.5rem;
    width: min(640px, 92vw);
    z-index: 1;
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.3);
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.notification-modal {
    width: min(680px, 94vw);
    padding: 1.8rem 2rem 2rem;
    border-radius: 18px;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.modal-header h2 {
    margin: 0;
}

.modal-close {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    cursor: pointer;
    font-size: 1.2rem;
}

.modal-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(140px, 1fr));
    gap: 1rem;
}

.notification-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.notification-form .form-row {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.notification-form label {
    color: #334155;
    font-weight: 600;
}

.notification-form input {
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
}

.notification-form textarea {
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    font-family: inherit;
    font-size: 0.95rem;
    resize: vertical;
}

.notification-form .modal-actions {
    justify-content: flex-end;
    margin-top: 0.5rem;
}

.modal-form label {
    color: #1f2937;
    font-weight: 600;
}

.modal-form input {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.modal-form select {
    width: 100%;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0.7rem 0.9rem;
    font-size: 0.92rem;
    color: #0b132b;
    appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%2364748b' d='M6 7.2L0.8 1.9 2.2 0.5 6 4.3 9.8 0.5 11.2 1.9z'/></svg>");
    background-repeat: no-repeat;
    background-position: right 0.9rem center;
    background-size: 12px;
}

.modal-form select:focus {
    border-color: #1abbff;
    box-shadow: 0 0 0 2px rgba(26, 187, 255, 0.2);
    outline: none;
}

.modal-form input:focus {
    border-color: #1abbff;
    box-shadow: 0 0 0 2px rgba(26, 187, 255, 0.2);
}

@media (max-width: 720px) {
    .profile-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-actions {
        width: 100%;
        align-items: flex-start;
    }

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

.content-card.profile-card.large {
    max-width: none;
    width: 100%;
    background: transparent;
    border: none;
    padding: 0;
    box-shadow: none;
}

.content-card.profile-card.large .profile-grid {
    grid-template-columns: 1fr 1fr;
    width: 100%;
}

@media (max-width: 960px) {
    .content-card.profile-card.large .profile-grid {
        grid-template-columns: 1fr;
    }
}
