/*
 * UI refresh (Laravel 11 upgrade) — presentation-only.
 * Intentionally avoids backend changes and keeps existing Bootstrap/SB-Admin theme.
 */

html {
    font-size: 14px;
}

body {
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Headings / typographic rhythm */
h1, h2, h3 {
    font-weight: 600;
}

h1 {
    font-size: 22px;
    margin: 0 0 14px;
}

h2 {
    font-size: 18px;
    margin: 0 0 12px;
}

h3 {
    font-size: 16px;
    margin: 0 0 10px;
}

.page-header {
    margin: 0 0 16px;
    padding: 0 0 12px;
}

/* Default layout (login/denied/etc.) */
body.layout-default {
    min-height: 100vh;
    margin: 0;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgb(241, 241, 241);
    background-image:
        radial-gradient(circle at 14% 0%, rgba(66, 139, 202, 0.16), rgba(66, 139, 202, 0) 54%),
        radial-gradient(circle at 88% 0%, rgba(26, 188, 156, 0.14), rgba(26, 188, 156, 0) 60%),
        radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0) 52%),
        radial-gradient(circle at 82% 0%, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0) 58%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.70), rgba(255, 255, 255, 0) 42%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(0, 0, 0, 0.06));
    background-repeat: no-repeat;
    background-attachment: fixed;
}

body.layout-default #wrapper {
    width: 100%;
}

body.layout-default .login-panel {
    max-width: 420px;
    margin: 0 auto;
}

body.layout-default .login-panel .panel-heading {
    text-align: center;
}

body.layout-default .login-panel .panel-heading h1 {
    margin: 0;
    font-size: 20px;
}

body.layout-default .login-panel .panel-body {
    padding-top: 18px;
}

body.layout-default .btn.btn-lg {
    padding-top: 10px;
    padding-bottom: 10px;
}

/* Bootstrap 3 grid centering helper for login */
body.layout-default .col-md-offset-4 {
    margin-left: auto;
    margin-right: auto;
}
body.layout-default .col-md-4 {
    float: none;
}

/* Layout spacing */
body:not(.layout-default) #wrapper {
    min-height: 100vh;
}

body.layout-default #wrapper {
    min-height: 0;
}

#page-wrapper {
    padding: 18px 18px 32px;
}

/* Common legacy page wrapper background */
.page-wrapper-bg {
    background-color: rgb(241, 241, 241);
    background-image:
        radial-gradient(circle at 14% 0%, rgba(66, 139, 202, 0.18), rgba(66, 139, 202, 0) 54%),
        radial-gradient(circle at 88% 0%, rgba(26, 188, 156, 0.16), rgba(26, 188, 156, 0) 60%),
        radial-gradient(circle at 12% 92%, rgba(66, 139, 202, 0.10), rgba(66, 139, 202, 0) 56%),
        radial-gradient(circle at 90% 96%, rgba(26, 188, 156, 0.09), rgba(26, 188, 156, 0) 60%),
        radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0) 52%),
        radial-gradient(circle at 82% 0%, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0) 58%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0) 42%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(0, 0, 0, 0.08));
    background-repeat: no-repeat;
    background-attachment: fixed;
}

/* Some dashboards expect extra top padding */
.page-wrapper-top-pad {
    padding-top: 20px;
}

/* Loader title used by dashboard loading overlay */
.loader-title {
    color: white;
    margin-top: 200px !important;
    width: 127%;
}

/* Reduce inline styles in legacy dashboards */
.d-panel-mt-20 {
    margin-top: 20px;
}

.d-panel-heading-h40 {
    height: 40px;
}

.panel-body-pad0-pt10 {
    padding: 0px;
    padding-top: 10px;
}

.pl-25 {
    padding-left: 25px;
}

/* Dashboard/home chart helpers */
.chart-h-350 {
    height: 350px;
}

/* Legend swatches keep existing colors inline */
.legend-swatch {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-right: 10px;
}

.legend-swatch-mx {
    margin-left: 10px;
    margin-right: 10px;
}

/* Common spacing helpers for legacy dashboards (Bootstrap 3 doesn't ship these) */
.mb-0 {
    margin-bottom: 0 !important;
}

.row-mb-20 {
    margin-bottom: 20px;
}

/* Small utilities to remove repetitive inline styles */
.text-brand-green {
    color: #59c37b;
}

.fw-bolder {
    font-weight: bolder;
}

.wh-100 {
    width: 100%;
    height: 100%;
}

.h-45 {
    height: 45px;
}

/* Repeated white card used in dashboard/home progress sections */
.progress-card {
    margin-bottom: 15px;
    background-color: #fff;
    padding-top: 20px;
    padding-bottom: 20px;
    box-shadow: 0 8px 6px -6px #afafaf;
}

/* Progress bar section (legacy dashboards) */
.progress-section {
    background-color: rgb(255, 255, 255);
}

.pin-img-50 {
    width: 50px;
}

/* Keep existing markup classes but remove repetitive inline styles */
.progressbar {
    width: 100%;
    background-color: rgb(222, 222, 222);
    border-radius: 10px;
    box-shadow: 0 8px 6px -6px #afafaf;
}

.proggress {
    background-color: rgb(26, 188, 156);
    height: 20px;
    border-radius: 10px;
    text-align: center;
    font-weight: bolder;
    color: #fff;
}

.progress-label {
    color: #ffffff;
    min-width: 100px !important;
    position: absolute;
    text-align: left;
}

/* Top nav */
.navbar {
    border-radius: 0;
}

.navbar-brand {
    padding-top: 10px;
    padding-bottom: 10px;
    height: auto;
}

.navbar-brand img {
    max-height: 36px;
    height: auto;
    width: auto;
}

.navbar-top-links > li > a {
    padding-top: 14px;
    padding-bottom: 14px;
}

/* Common components */
.panel,
.well,
.modal-content,
.dropdown-menu {
    border-radius: 10px;
}

.panel-heading {
    padding: 14px 16px;
}

.panel-body {
    padding: 16px;
}

.btn {
    border-radius: 10px;
}

.form-control {
    border-radius: 10px;
    height: 38px;
    padding: 8px 12px;
}

textarea.form-control {
    height: auto;
    min-height: 90px;
}

.input-group .form-control {
    height: 38px;
}

/* Tables */
.table > thead > tr > th,
.table > tbody > tr > td {
    padding: 10px 12px;
    vertical-align: middle;
}

/* Product edit pricing table: keep cell contents top-aligned */
.table > tbody#prices > tr > td {
    vertical-align: top;
}

/* Sidebar readability (SB Admin 2 / MetisMenu) */
.sidebar .nav > li > a {
    padding: 10px 14px;
}

.sidebar .nav > li > a .fa {
    width: 18px;
    text-align: center;
    margin-right: 8px;
}

.sidebar .nav-second-level > li > a {
    padding-left: 36px;
}

.sidebar .nav-third-level > li > a {
    padding-left: 50px;
}

.sidebar .badge {
    font-size: 11px;
    line-height: 1;
}

/* Legacy badge variant used in dashboards */
.badge-warning {
    background-color: #f89406;
}

.sidebar .nav > li > a,
.sidebar .nav-second-level > li > a,
.sidebar .nav-third-level > li > a {
    font-size: 13px;
}

/* Colorful sidebar (uses existing blue/teal palette) */
.navbar-default.sidebar {
    background-color: #428bca;
    background-image:
        linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0) 30%),
        linear-gradient(180deg, rgba(66, 139, 202, 1), rgba(26, 188, 156, 0.98));
    border-color: transparent;
}

.navbar-default.sidebar .sidebar-nav.navbar-collapse {
    background: transparent;
}

.sidebar ul li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.sidebar .nav > li > a,
.sidebar .nav-second-level > li > a,
.sidebar .nav-third-level > li > a {
    color: rgba(255, 255, 255, 0.92);
}

.sidebar .nav > li > a:hover,
.sidebar .nav > li > a:focus,
.sidebar .nav-second-level > li > a:hover,
.sidebar .nav-second-level > li > a:focus,
.sidebar .nav-third-level > li > a:hover,
.sidebar .nav-third-level > li > a:focus {
    background-color: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    box-shadow: inset 3px 0 0 rgba(255, 255, 255, 0.35);
}

.sidebar ul li.active > a,
.sidebar ul li a.active {
    background-color: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    font-weight: 600;
    box-shadow: inset 4px 0 0 rgba(255, 255, 255, 0.55);
}

.sidebar .nav-second-level,
.sidebar .nav-third-level {
    background-color: rgba(0, 0, 0, 0.10);
}

.sidebar .fa.arrow {
    color: rgba(255, 255, 255, 0.75);
}

/* Navbar search dropdown should fit smaller screens */
@media (max-width: 768px) {
    .row-search-box {
        width: 90vw;
        max-width: 420px;
    }
}

/* DataTables */
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    height: 38px;
}

/* Better spacing between stacked form rows */
.form-group {
    margin-bottom: 14px;
}

/* Dashboard widgets (stat cards / panels) */
.stat-box {
    border-radius: 12px;
    border: solid 1px #dedede;
    background-color: #ffffff;
    height: 130px;
    padding: 10px;
}

.stat-total {
    letter-spacing: -0.2px;
    font-size: 30px;
    font-weight: 100;
    padding: 10px 0px 10px 0px;
    color: #59c37b;
}

.stat-title {
    font-weight: 400;
}

.d-panel {
    border-radius: 12px !important;
}

.d-panel-heading {
    border-top-left-radius: 12px !important;
    border-top-right-radius: 12px !important;
    border: solid 0px;
    background-color: #f5f5f5 !important;
    min-height: 50px;
}

.d-panel-title {
    text-transform: uppercase;
    font-size: 15px;
    font-weight: 400;
}

.d-year-title {
    font-size: 30px;
    font-weight: 100;
    padding-left: 25px;
}

.chart-stat {
    height: 100px;
    border-right: solid 1px #ddd;
    margin-top: 10px;
}

.chart-stat-last {
    height: 100px;
    margin-top: 10px;
}

/* STAT COMPARE (legacy dashboard) */
.left-pan-navi {
    width: 5%;
    cursor: pointer;
}

.mid-pan-navi {
    width: 90%;
    text-align: center;
}

.right-pan-navi {
    width: 5%;
    text-align: right;
    cursor: pointer;
}

.top-nav-stat {
    position: relative;
    display: inline-block;
    vertical-align: middle;
    width: 100%;
}

.stat-com-box {
    padding-top: 25px;
    padding-bottom: 25px;
}

.left-con-stat {
    text-align: right;
    padding: 20px;
    font-weight: bolder;
    font-size: 15px;
}

.desc-left {
    font-size: 15px;
    color: #777777;
}

/* Dashboard loader + chart compare helpers (legacy dashboard) */
.desc-right {
    text-align: left;
    padding: 20px;
    font-weight: bolder;
    font-size: 30px;
    border-left: solid 1px #ddd;
}

.chart-stat-box {
    display: block;
    width: 500px;
    height: 250px;
}

.loader {
    background-color: rgb(54 50 50 / 95%);
    height: 100%;
    width: 100%;
    position: fixed;
    z-index: 1000;
    margin-top: 0px;
    top: 0px;
}

.loader-centered {
    position: absolute;
    left: 50%;
    top: 50%;
    height: 200px;
    width: 200px;
    margin-top: -100px;
    margin-left: -132px;
}

.object {
    width: 50px;
    height: 50px;
    background-color: rgba(255, 255, 255, 0);
    margin-right: auto;
    margin-left: auto;
    border: 4px solid #fff;
    left: 73px;
    top: 73px;
    position: absolute;
}

.square-one {
    -webkit-animation: first_object_animate 1s infinite ease-in-out;
    animation: first_object_animate 1s infinite ease-in-out;
}

.square-two {
    -webkit-animation: second_object 1s forwards, second_object_animate 1s infinite ease-in-out;
    animation: second_object 1s forwards, second_object_animate 1s infinite ease-in-out;
}

.square-three {
    -webkit-animation: third_object 1s forwards, third_object_animate 1s infinite ease-in-out;
    animation: third_object 1s forwards, third_object_animate 1s infinite ease-in-out;
}

@-webkit-keyframes second_object {
    100% {
        width: 100px;
        height: 100px;
        left: 48px;
        top: 48px;
    }
}

@keyframes second_object {
    100% {
        width: 100px;
        height: 100px;
        left: 48px;
        top: 48px;
    }
}

@-webkit-keyframes third_object {
    100% {
        width: 150px;
        height: 150px;
        left: 23px;
        top: 23px;
    }
}

@keyframes third_object {
    100% {
        width: 150px;
        height: 150px;
        left: 23px;
        top: 23px;
    }
}

@-webkit-keyframes first_object_animate {
    0% {
        -webkit-transform: perspective(100px);
    }
    50% {
        -webkit-transform: perspective(100px) rotateY(-180deg);
    }
    100% {
        -webkit-transform: perspective(100px) rotateY(-180deg) rotateX(-180deg);
    }
}

@keyframes first_object_animate {
    0% {
        transform: perspective(100px) rotateX(0deg) rotateY(0deg);
        -webkit-transform: perspective(100px) rotateX(0deg) rotateY(0deg);
    }
    50% {
        transform: perspective(100px) rotateX(-180deg) rotateY(0deg);
        -webkit-transform: perspective(100px) rotateX(-180deg) rotateY(0deg);
    }
    100% {
        transform: perspective(100px) rotateX(-180deg) rotateY(-180deg);
        -webkit-transform: perspective(100px) rotateX(-180deg) rotateY(-180deg);
    }
}

@-webkit-keyframes second_object_animate {
    0% {
        -webkit-transform: perspective(200px);
    }
    50% {
        -webkit-transform: perspective(200px) rotateY(180deg);
    }
    100% {
        -webkit-transform: perspective(200px) rotateY(180deg) rotateX(180deg);
    }
}

@keyframes second_object_animate {
    0% {
        transform: perspective(200px) rotateX(0deg) rotateY(0deg);
        -webkit-transform: perspective(200px) rotateX(0deg) rotateY(0deg);
    }
    50% {
        transform: perspective(200px) rotateX(180deg) rotateY(0deg);
        -webkit-transform: perspective(200px) rotateX(180deg) rotateY(0deg);
    }
    100% {
        transform: perspective(200px) rotateX(180deg) rotateY(180deg);
        -webkit-transform: perspective(200px) rotateX(180deg) rotateY(180deg);
    }
}

@-webkit-keyframes third_object_animate {
    0% {
        -webkit-transform: perspective(300px);
    }
    50% {
        -webkit-transform: perspective(300px) rotateY(-180deg);
    }
    100% {
        -webkit-transform: perspective(300px) rotateY(-180deg) rotateX(-180deg);
    }
}

@keyframes third_object_animate {
    0% {
        transform: perspective(300px) rotateX(0deg) rotateY(0deg);
        -webkit-transform: perspective(300px) rotateX(0deg) rotateY(0deg);
    }
    50% {
        transform: perspective(300px) rotateX(-180deg) rotateY(0deg);
        -webkit-transform: perspective(300px) rotateX(-180deg) rotateY(0deg);
    }
    100% {
        transform: perspective(300px) rotateX(-180deg) rotateY(-180deg);
        -webkit-transform: perspective(300px) rotateX(-180deg) rotateY(-180deg);
    }
}

/* Reduce heavy inline paddings visually */
#page-wrapper .row {
    margin-bottom: 14px;
}
