:root {
    color-scheme: light;
    --ink: #15233d;
    --navy: #11213d;
    --navy-soft: #1b3154;
    --muted: #718195;
    --line: #e3ebf0;
    --primary: #168caf;
    --primary-dark: #0d6f8e;
    --cyan-soft: #e8f7fa;
    --surface: #fff;
    --canvas: #f3f8fa;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--canvas);
    color: var(--ink);
    font-family: "Cairo", Tahoma, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.8;
    -webkit-font-smoothing: antialiased;
}

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

.auth-layout {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 32px 18px;
    background:
        radial-gradient(ellipse at 15% 10%, rgba(22, 140, 175, .13), transparent 36%),
        radial-gradient(ellipse at 90% 90%, rgba(17, 33, 61, .1), transparent 32%),
        var(--canvas);
}

.auth-card {
    width: min(100%, 450px);
    padding: 38px 40px 30px;
    border: 1px solid rgba(210, 228, 234, .9);
    border-radius: 24px;
    background: var(--surface);
    box-shadow: 0 25px 70px rgba(17, 33, 61, .11);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -.4px;
}

.brand-centered {
    display: flex;
    justify-content: center;
    margin-bottom: 32px;
}

.brand-mark {
    display: grid;
    width: 37px;
    height: 37px;
    place-items: center;
    border-radius: 11px;
    background: linear-gradient(145deg, #24a7c2, #0d6d8d);
    color: #fff;
    font-size: 19px;
    box-shadow: 0 8px 18px rgba(15, 111, 142, .22);
}

.eyebrow {
    color: var(--primary);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .2px;
}

.auth-card h1 {
    margin: 5px 0 6px;
    font-size: 24px;
    letter-spacing: -.5px;
}

.muted,
.auth-footnote,
.field-hint {
    color: var(--muted);
}

.muted {
    margin: 0 0 24px;
}

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

.auth-form label {
    margin-top: 5px;
    font-size: 13px;
    font-weight: 700;
}

.auth-form input:not([type="hidden"]) {
    width: 100%;
    height: 49px;
    padding: 0 15px;
    border: 1px solid #dbe7eb;
    border-radius: 11px;
    outline: none;
    background: #fff;
    color: var(--ink);
    font: inherit;
    transition: border-color .15s, box-shadow .15s;
}

.auth-form input:focus {
    border-color: #53b7c9;
    box-shadow: 0 0 0 4px rgba(22, 140, 175, .11);
}

.field-hint {
    margin: -5px 0 3px;
    font-size: 11px;
}

.button {
    display: inline-flex;
    min-height: 46px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 11px;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
    transition: background .15s, transform .15s;
}

.button-primary {
    margin-top: 13px;
    background: linear-gradient(135deg, var(--primary), #0d7494);
    color: #fff;
}

.button-primary:hover {
    transform: translateY(-1px);
    background: linear-gradient(135deg, #117d9c, var(--primary-dark));
}

.button-full {
    width: 100%;
}

.auth-footnote {
    margin: 19px 0 0;
    text-align: center;
    font-size: 11px;
}

.alert {
    margin-bottom: 17px;
    padding: 10px 13px;
    border-radius: 8px;
    font-size: 12px;
}

.alert-error {
    border: 1px solid #f5d1d2;
    background: #fff5f5;
    color: #a3343a;
}

.alert-info {
    border: 1px solid #d8e5fb;
    background: #f3f7ff;
    color: #34538a;
}

.alert-warning {
    border: 1px solid #f1dfb4;
    background: #fff9e9;
    color: #795d1f;
}

.dashboard-layout {
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    z-index: 2;
    top: 0;
    right: 0;
    bottom: 0;
    display: flex;
    width: 270px;
    flex-direction: column;
    padding: 27px 19px 18px;
    border-left: 1px solid rgba(221, 233, 238, .9);
    background: linear-gradient(180deg, #fff 0%, #fbfeff 100%);
    box-shadow: -8px 0 28px rgba(17, 33, 61, .025);
}

.sidebar .brand {
    padding: 0 9px 29px;
    border-bottom: 1px solid #edf3f5;
}

.sidebar-label {
    padding: 22px 10px 9px;
    color: #94a5b1;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .6px;
}

.sidebar-nav {
    display: flex;
    flex: 1;
    flex-direction: column;
}

.nav-link {
    display: flex;
    min-height: 46px;
    align-items: center;
    gap: 11px;
    padding: 0 12px;
    border-radius: 11px;
    color: #6a7d8e;
    font-size: 13px;
    font-weight: 600;
}

.nav-link.active {
    background: linear-gradient(90deg, #e4f5f8, #effafd);
    color: var(--primary);
    box-shadow: inset -3px 0 0 var(--primary);
}

.nav-icon {
    display: grid;
    width: 22px;
    place-items: center;
    font-size: 19px;
    line-height: 1;
}

.apps-label {
    padding-top: 28px;
}

.empty-apps {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px 12px;
    color: #9aa4b3;
    font-size: 11px;
}

.empty-apps-icon {
    color: #b1b8c5;
    font-size: 17px;
}

.app-nav-link {
    display: flex;
    min-height: 54px;
    align-items: center;
    gap: 9px;
    padding: 6px 10px;
    border: 1px solid #e1eef1;
    border-radius: 11px;
    background: #f7fcfd;
    color: var(--ink);
}

.app-nav-link.selected {
    border-color: #b9dfe5;
    background: linear-gradient(90deg, #e3f6f8, #f6fcfd);
    box-shadow: inset -3px 0 0 var(--primary);
}

.app-nav-icon,
.app-large-icon {
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: #fff2dc;
}

.app-nav-icon {
    width: 31px;
    height: 31px;
    font-size: 17px;
}

.app-nav-copy {
    display: grid;
    min-width: 0;
    flex: 1;
    line-height: 1.45;
}

.app-nav-copy strong {
    overflow: hidden;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-nav-copy small {
    color: #7ba0a8;
    font-size: 9px;
}

.app-live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #24b68c;
    box-shadow: 0 0 0 3px rgba(36, 182, 140, .13);
}

.app-live-dot.is-off {
    background: #c2cbd2;
    box-shadow: none;
}

.app-subnav {
    display: grid;
    gap: 2px;
    margin: 3px 10px 9px 0;
    padding: 3px 8px 3px 0;
    border-right: 1px solid #d9e9ed;
}

.app-subnav a {
    display: block;
    padding: 5px 9px;
    border-radius: 7px;
    color: #8396a0;
    font-size: 11px;
}

.app-subnav a:hover,
.app-subnav a.active {
    background: #eef9fa;
    color: var(--primary-dark);
    font-weight: 700;
}

.sidebar-bottom {
    padding-top: 14px;
    border-top: 1px solid #f0f2f7;
}

.connection-status {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 8px 15px;
    color: #8591a4;
    font-size: 10px;
}

.status-dot,
.online-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #37b98f;
    box-shadow: 0 0 0 3px rgba(55, 185, 143, .12);
}

.user-card {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 10px;
    padding: 11px 8px 3px;
    border-top: 1px solid #f0f2f7;
}

.avatar {
    display: grid;
    width: 35px;
    height: 35px;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 11px;
    background: #e9eaff;
    color: var(--primary);
    font-size: 14px;
    font-weight: 700;
}

.user-details {
    display: grid;
    min-width: 0;
    flex: 1;
    line-height: 1.5;
}

.user-details strong {
    overflow: hidden;
    font-size: 11px;
    text-overflow: ellipsis;
}

.user-details small {
    color: #98a2b1;
    font-size: 10px;
}

.icon-button {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #8994a6;
    cursor: pointer;
    font-size: 19px;
}

.icon-button:hover {
    background: #f3f4f9;
    color: #d0525b;
}

.main-content {
    max-width: 1480px;
    min-height: 100vh;
    margin-right: 270px;
    padding: 31px 46px 22px;
}

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
}

.breadcrumb {
    margin-bottom: 1px;
    color: #98a2b2;
    font-size: 11px;
}

.breadcrumb span {
    padding: 0 5px;
    color: #c4cad4;
}

.topbar h1 {
    margin: 0;
    font-size: 23px;
    letter-spacing: -.4px;
}

.topbar-user {
    display: flex;
    align-items: center;
    gap: 9px;
    color: #6d788c;
    font-size: 12px;
}

.online-dot {
    width: 6px;
    height: 6px;
}

.welcome-card {
    position: relative;
    display: flex;
    min-height: 205px;
    align-items: center;
    justify-content: space-between;
    overflow: hidden;
    padding: 32px 38px;
    border-radius: 20px;
    background:
        radial-gradient(circle at 12% 15%, rgba(59, 178, 196, .22), transparent 30%),
        linear-gradient(112deg, #10223f 0%, #172d50 55%, #1e4660 100%);
    color: #fff;
    box-shadow: 0 18px 32px rgba(17, 33, 61, .17);
}

.welcome-card .eyebrow {
    color: #8ed8e2;
}

.welcome-card h2 {
    margin: 4px 0 5px;
    font-size: 24px;
}

.welcome-card p {
    max-width: 500px;
    margin: 0;
    color: #c4dce3;
    font-size: 12px;
}

.welcome-art {
    position: relative;
    width: 160px;
    height: 140px;
    flex: 0 0 auto;
    margin-left: 4%;
}

.art-square {
    position: absolute;
    display: grid;
    width: 77px;
    height: 87px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .5);
    border-radius: 15px;
    transform: rotate(13deg);
}

.art-square-back {
    top: 31px;
    right: 46px;
    background: rgba(60, 181, 198, .09);
}

.art-square-front {
    top: 18px;
    right: 60px;
    background: rgba(40, 170, 192, .2);
    box-shadow: 0 12px 24px rgba(4, 19, 43, .25);
}

.art-square-front span {
    color: #fff;
    font-size: 28px;
}

.art-orbit {
    position: absolute;
    top: 12px;
    right: 33px;
    width: 116px;
    height: 116px;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 50%;
}

.section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 34px 0 16px;
}

.section-heading h2 {
    margin: 0;
    font-size: 17px;
}

.section-heading p {
    margin: 2px 0 0;
    color: #929daf;
    font-size: 11px;
}

.count-badge {
    padding: 4px 11px;
    border: 1px solid #e6e9f2;
    border-radius: 20px;
    background: #fff;
    color: #7d889b;
    font-size: 10px;
}

.empty-state {
    display: grid;
    min-height: 280px;
    align-content: center;
    justify-items: center;
    padding: 30px;
    border: 1px dashed #c9dfe5;
    border-radius: 17px;
    background: rgba(255, 255, 255, .78);
    box-shadow: 0 10px 26px rgba(17, 33, 61, .025);
    text-align: center;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.app-dashboard-card {
    position: relative;
    display: block;
    min-height: 0;
    overflow: hidden;
    border: 1px solid #deebee;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 9px 25px rgba(17, 33, 61, .045);
    transition: transform .18s, box-shadow .18s, border-color .18s;
}

.app-dashboard-card::after {
    position: absolute;
    bottom: -44px;
    left: -24px;
    width: 130px;
    height: 130px;
    border: 1px solid rgba(22, 140, 175, .12);
    border-radius: 50%;
    content: "";
}

.app-dashboard-card:hover {
    border-color: #aad6dd;
    box-shadow: 0 15px 31px rgba(17, 33, 61, .09);
    transform: translateY(-3px);
}

.app-dashboard-image {
    position: relative;
    display: grid;
    aspect-ratio: 1 / 1;
    height: auto;
    place-items: center;
    overflow: hidden;
    border-bottom: 1px solid #edf3f4;
    background:
        radial-gradient(circle at 80% 15%, rgba(93, 195, 205, .25), transparent 32%),
        linear-gradient(135deg, #e8f7fa, #f7fbfc 65%, #dceff2);
}

.app-dashboard-image::before,
.app-dashboard-image::after {
    position: absolute;
    border: 1px solid rgba(22, 140, 175, .12);
    border-radius: 50%;
    content: "";
}

.app-dashboard-image::before {
    width: 210px;
    height: 210px;
}

.app-dashboard-image::after {
    width: 130px;
    height: 130px;
}

.app-dashboard-image img {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: 0;
    object-fit: cover;
}

.app-dashboard-fallback {
    position: relative;
    z-index: 1;
    display: grid;
    width: 100%;
    height: 100%;
    place-items: center;
    border: 0;
    border-radius: 0;
    background: linear-gradient(145deg, #fff3de, #ffe5b6);
    font-size: 46px;
}

.app-image-status {
    position: absolute;
    z-index: 2;
    top: 12px;
    right: 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border: 1px solid rgba(255, 255, 255, .7);
    border-radius: 20px;
    background: rgba(255, 255, 255, .82);
    color: #298b73;
    font-size: 9px;
    font-weight: 700;
}

.app-dashboard-content {
    min-width: 0;
    padding: 17px 19px 19px;
}

.app-dashboard-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.app-arrow {
    color: #a9bac1;
    font-size: 18px;
    transition: color .18s, transform .18s;
}

.app-dashboard-card:hover .app-arrow {
    color: var(--primary);
    transform: translateX(-4px);
}

.app-dashboard-card h3 {
    margin: 2px 0 1px;
    font-size: 16px;
}

.app-dashboard-card p {
    overflow: hidden;
    margin: 0;
    color: #94a4ad;
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.detail-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 4px 0 15px;
}

.detail-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.detail-tabs {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px;
    border: 1px solid #dfebee;
    border-radius: 11px;
    background: #f7fcfd;
}

.detail-tab {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    padding: 0 12px;
    border-radius: 8px;
    color: #718595;
    font-size: 10px;
    font-weight: 700;
}

.detail-tab.active,
.detail-tab:hover {
    background: #fff;
    color: var(--primary-dark);
    box-shadow: 0 2px 7px rgba(17, 33, 61, .07);
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--primary-dark);
    font-size: 11px;
    font-weight: 700;
}

.back-link:hover {
    color: var(--primary);
}

.detail-slug {
    padding: 4px 9px;
    border: 1px solid #dcebed;
    border-radius: 7px;
    background: #f8fcfd;
    color: #8aa0a8;
    direction: ltr;
    font-family: monospace;
    font-size: 9px;
}

.app-control-card {
    overflow: hidden;
    border: 1px solid #dfebee;
    border-radius: 17px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(17, 33, 61, .045);
}

.feature-card {
    margin-top: 16px;
}

.app-overview-card {
    overflow: hidden;
    border: 1px solid #dfebee;
    border-radius: 17px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(17, 33, 61, .045);
}

.app-overview-hero {
    display: flex;
    align-items: center;
    gap: 17px;
    padding: 25px;
    background:
        radial-gradient(circle at 15% 0, rgba(54, 178, 194, .16), transparent 35%),
        linear-gradient(100deg, #f4fbfc, #fbfeff);
}

.app-overview-hero img {
    display: block;
    width: 76px;
    height: 76px;
    max-width: 76px;
    max-height: 76px;
    flex: 0 0 auto;
    border-radius: 18px;
    object-fit: cover;
    box-shadow: 0 8px 18px rgba(17, 33, 61, .13);
}

.app-overview-hero h2 {
    margin: 2px 0 1px;
    font-size: 22px;
}

.app-overview-hero p {
    margin: 0;
    color: #8297a0;
    direction: ltr;
    font-family: monospace;
    font-size: 11px;
}

.app-overview-hero .connected-badge {
    margin-right: auto;
}

.app-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    border-top: 1px solid #edf3f4;
    background: #edf3f4;
}

.app-stats-grid div {
    display: grid;
    min-height: 88px;
    align-content: center;
    gap: 4px;
    padding: 16px 19px;
    background: #fff;
}

.app-stats-grid small {
    color: #8b9da5;
    font-size: 11px;
}

.app-stats-grid strong {
    color: var(--ink);
    font-size: 15px;
}

.overview-shortcuts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 17px;
}

.overview-shortcuts a {
    display: grid;
    gap: 2px;
    padding: 17px 19px;
    border: 1px solid #dfebee;
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 7px 18px rgba(17, 33, 61, .035);
}

.overview-shortcuts a:hover {
    border-color: #a9d7de;
}

.overview-shortcuts strong {
    font-size: 14px;
}

.overview-shortcuts span {
    color: #8398a0;
    font-size: 11px;
}

.overview-shortcuts b {
    align-self: end;
    color: var(--primary);
    font-size: 18px;
}

.app-control-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 23px;
    border-bottom: 1px solid #edf3f4;
    background: linear-gradient(100deg, #fbfeff, #f2fafb);
}

.app-title-wrap {
    display: flex;
    align-items: center;
    gap: 13px;
}

.app-large-icon {
    width: 48px;
    height: 48px;
    font-size: 25px;
}

.app-control-header h3,
.ads-panel-title h3 {
    margin: 0;
    font-size: 15px;
}

.app-control-header p,
.ads-panel-title p {
    margin: 1px 0 0;
    color: #8294a0;
    font-size: 10px;
}

.app-control-header code {
    color: #66828c;
    font-family: monospace;
    font-size: 10px;
}

.connected-badge,
.ads-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 20px;
    background: #eaf9f4;
    color: #238969;
    font-size: 10px;
    font-weight: 700;
}

.connected-badge span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #29b58e;
}

.ads-panel-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 23px 17px;
}

.ads-status {
    background: #e7f6fa;
    color: var(--primary-dark);
}

.ads-status.disabled {
    background: #f1f3f5;
    color: #7f8992;
}

.ads-form {
    padding: 0 23px 21px;
}

.ads-form::before {
    display: block;
    height: 1px;
    margin: 0 -23px 18px;
    background: #edf3f4;
    content: "";
}

.ads-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 13px 15px;
    border: 1px solid #e4eef0;
    border-radius: 13px;
    background: linear-gradient(100deg, #fbfdfe, #f8fcfd);
    box-shadow: 0 3px 10px rgba(17, 33, 61, .025);
}

.ads-toggle-row + .ads-toggle-row {
    margin-top: 9px;
}

.platform-sub-setting {
    margin-right: 24px;
    border-style: dashed;
    background: #fcfeff;
}

.ads-toggle-row strong {
    display: block;
    font-size: 11px;
}

.ads-toggle-row small {
    display: block;
    color: #8798a3;
    font-size: 9px;
}

.switch {
    position: relative;
    width: 42px;
    height: 23px;
    flex: 0 0 auto;
}

.switch input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.switch span {
    position: absolute;
    inset: 0;
    border-radius: 20px;
    background: #cbd6db;
    cursor: pointer;
    transition: background .2s;
}

.switch span::after {
    position: absolute;
    top: 3px;
    right: 3px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background: #fff;
    content: "";
    box-shadow: 0 1px 4px rgba(17, 33, 61, .18);
    transition: transform .2s;
}

.switch input:checked + span {
    background: var(--primary);
}

.switch input:checked + span::after {
    transform: translateX(-19px);
}

.ad-unit-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 11px;
    margin-top: 15px;
}

.ad-unit-card {
    position: relative;
    display: grid;
    gap: 15px;
    min-width: 0;
    padding: 15px;
    overflow: hidden;
    border: 1px solid #deeaed;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 5px 14px rgba(17, 33, 61, .035);
}

.ad-unit-card::before {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 3px;
    background: var(--primary);
    content: "";
}

.ad-unit-interstitial::before {
    background: #7180d8;
}

.ad-unit-rewarded::before {
    background: #d59b4f;
}

.ad-unit-heading {
    display: flex;
    align-items: center;
    gap: 9px;
}

.ad-unit-icon {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 10px;
    background: #e8f7fa;
    color: var(--primary-dark);
    font-size: 18px;
}

.ad-unit-interstitial .ad-unit-icon {
    background: #eef0ff;
    color: #5968c5;
}

.ad-unit-rewarded .ad-unit-icon {
    background: #fff6e7;
    color: #b47a2d;
}

.ad-unit-heading span:last-child {
    display: grid;
    line-height: 1.35;
}

.ad-unit-heading strong {
    color: var(--ink);
    font-family: Arial, sans-serif;
    font-size: 11px;
}

.ad-unit-heading small {
    color: #899aa3;
    font-size: 9px;
}

.ad-unit-card label {
    display: grid;
    gap: 5px;
    color: #5f7180;
    font-size: 10px;
    font-weight: 700;
}

.ad-unit-card input {
    width: 100%;
    height: 40px;
    padding: 0 9px;
    border: 1px solid #dce8eb;
    border-radius: 9px;
    outline: 0;
    color: #647783;
    direction: ltr;
    font-family: monospace;
    font-size: 9px;
}

.ad-unit-card input:focus {
    border-color: #61becb;
    box-shadow: 0 0 0 3px rgba(22, 140, 175, .1);
}

.ads-form-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin-top: 17px;
}

.ads-form-footer .button {
    min-height: 39px;
    padding: 0 18px;
    font-size: 11px;
}

.test-note {
    color: #a18353;
    font-size: 10px;
}

/* Shared dashboard sizing and RTL alignment. AdMob values remain LTR by nature. */
html,
body {
    direction: rtl;
}

body {
    font-size: 15px;
}

.sidebar-label {
    font-size: 11px;
}

.nav-link,
.app-nav-link {
    font-size: 14px;
}

.app-nav-copy small {
    font-size: 10px;
}

.breadcrumb,
.topbar-user {
    font-size: 12px;
}

.section-heading p,
.welcome-card p,
.app-control-header p,
.ads-panel-title p {
    font-size: 12px;
}

.section-heading h2 {
    font-size: 19px;
}

.app-dashboard-card h3,
.app-control-header h3,
.ads-panel-title h3 {
    font-size: 17px;
}

.app-dashboard-card p,
.app-control-header code {
    font-size: 11px;
}

.connected-badge,
.ads-status,
.count-badge {
    font-size: 11px;
}

.ads-toggle-row {
    min-height: 66px;
    padding: 15px 17px;
}

.ads-toggle-row strong {
    font-size: 13px;
}

.ads-toggle-row small {
    margin-top: 2px;
    font-size: 11px;
}

.ads-app-id-row {
    align-items: center;
}

.ads-app-id-row .app-id-field {
    display: block;
    width: min(44%, 430px);
    margin: 0;
}

.app-id-field input {
    width: 100%;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid #d6e5e9;
    border-radius: 10px;
    outline: 0;
    background: #fff;
    color: #526d79;
    direction: ltr;
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: 13px;
    text-align: left;
}

.app-id-field input:focus {
    border-color: #61becb;
    box-shadow: 0 0 0 4px rgba(22, 140, 175, .1);
}

.ad-unit-heading strong {
    font-size: 13px;
}

.ad-unit-heading small,
.ad-unit-card label {
    font-size: 11px;
}

.ad-unit-card {
    gap: 17px;
    padding: 17px;
}

.ad-unit-card input {
    min-height: 43px;
    font-size: 11px;
    text-align: left;
}

.ads-form-footer .button {
    font-size: 13px;
}

.test-note {
    font-size: 11px;
}

@media (max-width: 650px) {
    .ads-app-id-row {
        align-items: stretch;
        flex-direction: column;
    }

    .ads-app-id-row .app-id-field {
        width: 100%;
    }
}

.notification-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 16px;
}

.notification-form {
    display: grid;
    gap: 13px;
    padding: 22px 23px 23px;
}

.notification-form label {
    display: grid;
    gap: 6px;
    color: #5f7180;
    font-size: 11px;
    font-weight: 700;
}

.notification-form input,
.notification-form select,
.notification-form textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #dce8eb;
    border-radius: 10px;
    outline: 0;
    background: #fff;
    color: var(--ink);
    font: inherit;
    font-size: 12px;
    transition: border-color .15s, box-shadow .15s;
}

.notification-form input,
.notification-form select {
    height: 42px;
}

.notification-form textarea {
    min-height: 105px;
    resize: vertical;
}

.notification-form input:focus,
.notification-form select:focus,
.notification-form textarea:focus {
    border-color: #61becb;
    box-shadow: 0 0 0 3px rgba(22, 140, 175, .1);
}

.notification-form-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin-top: 4px;
}

.notification-form-footer .button {
    min-height: 40px;
    padding: 0 20px;
    font-size: 11px;
}

.notification-side-card {
    align-self: start;
    padding: 21px;
    border: 1px solid #dfebee;
    border-radius: 17px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(17, 33, 61, .045);
}

.notification-side-card h3 {
    margin: 0 0 10px;
    font-size: 14px;
}

.notification-side-card p {
    margin: 8px 0 0;
    color: #8294a0;
    font-size: 11px;
}

.notification-side-card code {
    direction: ltr;
    font-family: monospace;
    font-size: 10px;
    overflow-wrap: anywhere;
}

.setup-status {
    display: inline-flex;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 700;
}

.setup-status-ready {
    background: #eaf9f4;
    color: #238969;
}

.setup-status-warning {
    background: #fff9e9;
    color: #795d1f;
}

.setup-path {
    display: block;
    margin-top: 10px;
    color: #667783;
}

.side-heading {
    margin-top: 24px !important;
}

.device-count {
    display: block;
    color: var(--primary-dark);
    font-size: 28px;
    line-height: 1.2;
}

.empty-illustration {
    display: grid;
    width: 69px;
    height: 69px;
    place-items: center;
    margin-bottom: 11px;
    border-radius: 20px;
    background: var(--cyan-soft);
}

.empty-window {
    position: relative;
    display: flex;
    width: 40px;
    height: 32px;
    gap: 3px;
    padding: 6px;
    border: 1.5px solid #249bb6;
    border-radius: 6px;
}

.empty-window i {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #9a9ef6;
}

.empty-window b {
    position: absolute;
    right: 11px;
    bottom: -15px;
    display: grid;
    width: 18px;
    height: 18px;
    place-items: center;
    border: 2px solid var(--canvas);
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-size: 13px;
    line-height: 1;
}

.empty-state h3 {
    margin: 4px 0 2px;
    font-size: 14px;
}

.empty-state p {
    max-width: 430px;
    margin: 0;
    color: #8995a8;
    font-size: 11px;
}

.page-footer {
    padding: 22px 0 0;
    color: #9ca6b5;
    font-size: 10px;
    text-align: center;
}

.page-footer span {
    padding: 0 5px;
    color: #c3c9d2;
}

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

    .main-content {
        margin-right: 220px;
        padding: 25px;
    }

    .app-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 650px) {
    .auth-card {
        padding: 30px 23px 25px;
    }

    .sidebar {
        position: static;
        width: 100%;
        height: auto;
        padding: 13px 16px;
        border-left: 0;
        border-bottom: 1px solid var(--line);
    }

    .sidebar .brand {
        padding: 0 2px 12px;
    }

    .sidebar-label {
        display: none;
    }

    .sidebar-nav {
        flex: initial;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
        padding-top: 9px;
    }

    .nav-link {
        min-height: 37px;
    }

    .apps-label {
        display: block;
        padding: 0;
    }

    .empty-apps {
        padding: 0 4px;
        font-size: 10px;
    }

    .sidebar-bottom {
        display: block;
        padding: 9px 0 0;
        border-top: 1px solid #f0f2f7;
    }

    .connection-status {
        display: none;
    }

    .user-card {
        padding: 7px 2px 0;
        border-top: 0;
    }

    .main-content {
        margin: 0;
        padding: 22px 17px;
    }

    .app-dashboard-card {
        min-height: 0;
    }

    .app-overview-hero {
        align-items: flex-start;
        flex-wrap: wrap;
        padding: 19px;
    }

    .app-overview-hero .connected-badge {
        width: 100%;
        margin-right: 0;
    }

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

    .overview-shortcuts {
        grid-template-columns: 1fr;
    }

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

    .app-control-header,
    .ads-panel-title,
    .ads-form-footer,
    .notification-form-footer {
        align-items: flex-start;
        flex-direction: column;
    }

    .notification-layout {
        grid-template-columns: 1fr;
    }

    .detail-toolbar-actions {
        align-items: flex-end;
        flex-direction: column;
        gap: 7px;
    }

    .ad-unit-grid {
        grid-template-columns: 1fr;
    }

    .topbar {
        margin-bottom: 17px;
    }

    .topbar-user {
        font-size: 10px;
    }

    .welcome-card {
        min-height: 175px;
        padding: 24px 21px;
    }

    .welcome-card h2 {
        max-width: 265px;
        font-size: 19px;
    }

    .welcome-card p {
        max-width: 265px;
        font-size: 11px;
    }

    .welcome-art {
        position: absolute;
        left: -47px;
        margin: 0;
        opacity: .55;
    }

    .empty-state {
        min-height: 245px;
        padding: 22px;
    }
}

@media (max-width: 380px) {
    .empty-apps {
        max-width: 135px;
        line-height: 1.4;
    }

    .topbar-user {
        gap: 6px;
    }
}
