/* ERP v2 - Stiluri personalizate */

:root {
    --water-blue-dark: #b3e5fc;
    --water-blue-light: #e1f5fe;
    --water-blue-accent: #ffffff;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Outfit', sans-serif;
    min-height: 100vh;
    background: linear-gradient(-45deg, var(--water-blue-dark), var(--water-blue-light), var(--water-blue-accent), #81d4fa);
    background-size: 400% 400%;
    animation: waterGradient 15s ease infinite;
    color: #01579b;
    -webkit-tap-highlight-color: transparent; /* Remove blue highlight on mobile */
}

.navbar-button-p {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 14px;
    color: #004d7a;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}



@keyframes waterGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}


.navbar {
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1000;
  padding-top: 10px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: none;
}

.navbar-limit {
  max-width: 3840px;
  margin: 0 auto 10px auto;
}

/* Premium Staggered Animations for individual widgets */
.view-enter .widget, 
.view-enter .stat-pill,
.view-enter .dashboard-panel-financial,
.view-enter .welcome-left,
.view-enter .clients-container > *,
.view-enter .clients-main-grid > *,
.view-enter .card,
.view-enter .classic-module-wrapper > * {
    opacity: 0;
    animation: revealUp 0.8s cubic-bezier(0.2, 1, 0.2, 1) both;
}

/* Staggered delays for children within a view-enter container */
.view-enter *:nth-child(1) { animation-delay: 0.05s; }
.view-enter *:nth-child(2) { animation-delay: 0.10s; }
.view-enter *:nth-child(3) { animation-delay: 0.15s; }
.view-enter *:nth-child(4) { animation-delay: 0.20s; }
.view-enter *:nth-child(5) { animation-delay: 0.25s; }
.view-enter *:nth-child(6) { animation-delay: 0.30s; }
.view-enter *:nth-child(7) { animation-delay: 0.35s; }
.view-enter *:nth-child(8) { animation-delay: 0.40s; }
.view-enter *:nth-child(9) { animation-delay: 0.45s; }
.view-enter *:nth-child(10) { animation-delay: 0.50s; }

/* Deep nesting staggered support */
.view-enter .dashboard-grid > *:nth-child(1) { animation-delay: 0.1s; }
.view-enter .dashboard-grid > *:nth-child(2) { animation-delay: 0.2s; }
.view-enter .dashboard-grid > *:nth-child(3) { animation-delay: 0.3s; }
.view-enter .dashboard-main-row > *:nth-child(1) { animation-delay: 0.4s; }
.view-enter .dashboard-main-row > *:nth-child(2) { animation-delay: 0.5s; }
.view-enter .dashboard-main-row > *:nth-child(3) { animation-delay: 0.6s; }

/* Exit animation applied to children too for a "falling away" effect */
.view-exit .widget, 
.view-exit .stat-pill,
.view-exit .dashboard-panel-financial {
    animation: revealDown 0.4s cubic-bezier(0.4, 0, 1, 1) both !important;
}

.view-exit *:nth-child(1) { animation-delay: 0.0s; }
.view-exit *:nth-child(2) { animation-delay: 0.05s; }
.view-exit *:nth-child(3) { animation-delay: 0.1s; }

@keyframes revealUp {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
        filter: blur(15px);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Loading Overlay - Slimmer & Sleeker */
#content-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: transparent;
    z-index: 2000;
}

#content-loader .progress-bar {
    height: 100%;
    width: 0;
    background: #0b3d91;
    box-shadow: 0 0 10px rgba(11, 61, 145, 0.5);
    transition: width 0.3s ease;
}

/* --------------------------------------
   PRINT UTILITIES
--------------------------------------- */
@media print {
    .navbar, .header-actions, .btn-glass, .btn-primary-v2, .hr-tabs, .search-wrapper, .v2-modal-footer, .navbar-tab-indicator, .status-indicator {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    #main-content {
        margin-top: 0 !important;
        padding: 0 !important;
    }
    
    .widget, .hr-card-widget {
        box-shadow: none !important;
        border: none !important;
        background: white !important;
        padding: 0 !important;
    }

    .print-only {
        display: block !important;
    }

    .no-print {
        display: none !important;
    }
}

.print-only {
    display: none;
}

/* Ascunde watermark-urile și elementele de UI din Cesium pe harta publică */
.cesium-viewer-bottom,
.cesium-viewer-toolbar,
.cesium-widget-credits {
    display: none !important;
}

#main-content {
  margin-top: 80px; /* Reduced from 100px */
  padding: 10px 50px; /* Top/bottom 10px as requested */
  max-width: 3840px;
  margin-left: auto;
  margin-right: auto;
  transition: opacity 0.3s ease;
}

.dashboard-grid {
}

.main-column-left, .main-column-right {
}

.navbar-margin {
  padding-left: 50px;
  padding-right: 50px;
  display: flex;
  align-items: center;
  position: relative; /* Parent for floating dropdown */
}

.navbar-logo {
  width: auto;
  min-width: 40px;
  height: auto;
  min-height: 48px; /* Slightly taller to accommodate different logo ratios */
  background-color: rgba(255,255,255, .8);
  box-shadow: rgba(100, 100, 111, 0.1) 0px 7px 29px 0px;
  border-radius: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px; /* Balanced padding for dynamic height */
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.navbar-logo-img {
    width: 40px;
    height: auto;
    display: block;
}

.navbar-tabs {
  margin-left: auto;
  display: flex;
  align-items: center;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.5);
  border-radius: 40px;
  padding: 0 5px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: rgba(100, 100, 111, 0.05) 0px 7px 29px 0px;
  position: relative; /* For sliding indicator */
}

.navbar-tab-indicator {
  position: absolute;
  height: 32px;
  background-color: #0b3d91;
  border-radius: 32px;
  transition: all 0.25s cubic-bezier(0.2, 1, 0.2, 1);
  z-index: 1;
  box-shadow: rgba(11, 61, 145, 0.3) 0px 4px 12px;
  top: 4px; /* Centered vertically (40-32)/2 */
}

.navbar-tab {
  margin: 0 2px;
  padding: 0 18px;
  height: 32px;
  border-radius: 32px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 2; /* Above indicator */
  text-decoration: none;
}

.navbar-tab:hover:not(.active) {
  background-color: rgba(255, 255, 255, 0.2);
}

.navbar-tab.active {
  background-color: transparent; /* Indicator handles background */
  box-shadow: none;
}

.navbar-tab-p {
  line-height: 32px;
  margin: 0;
}

.navbar-tab-content {
  display: flex;
  align-items: center;
}

.navbar-tab .navbar-icon {
  width: auto;
  height: auto;
  margin-right: 8px;
}

.navbar-tab .navbar-icon i {
  font-size: 1.1rem;
  color: #01579b;
}

.navbar-tab.active .navbar-icon i {
  color: #ffffff;
}

.navbar-tab-p {
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
  font-size: 14px;
  color: #01579b;
  margin: 0;
  white-space: nowrap;
}

.navbar-tab.active .navbar-tab-p {
  color: #ffffff;
  font-weight: 600;
}

.navbar-item {
  margin-left: 10px;
  position: relative;
}

.navbar-item-content {
  width: auto;
  min-width: 40px;
  height: 40px;
  border-radius: 40px;
  background-color: rgba(255, 255, 255, 0.7);
  box-shadow: rgba(100, 100, 111, 0.05) 0px 7px 29px 0px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s ease;
  padding: 0 10px;
}

.navbar-item:hover .navbar-item-content {
  background-color: rgba(255, 255, 255, 1);
}

.navbar-notificari .navbar-item-content,
.navbar-user .navbar-item-content {
  padding: 0;
  width: 40px;
}


.navbar-dropdown {
  position: absolute;
  top: 70px; /* 40px height + 10px distance */
  width: 250px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: rgba(100, 100, 111, 0.15) 0px 10px 40px 0px;
  z-index: 100;
  padding: 15px;
  
  /* Snappy Slide, Fade & Move Animation */
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease, right 0.25s cubic-bezier(0.2, 1, 0.2, 1);
}

.navbar-dropdown.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

#dropdown-content-area {
  transition: opacity 0.2s ease;
}

.navbar-item.open .navbar-item-content {
  background-color: rgba(255, 255, 255, 1);
}

.navbar-item-content .navbar-icon {
  width: auto;
  height: auto;
}

.navbar-item-content .navbar-icon i {
  font-size: 1.25rem;
  color: #01579b;
}

.navbar-button-p {
    font-size: 14px;
    font-weight: 500;
    margin-left: 8px;
    color: #01579b;
}
.navbar-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.navbar-icon i {
  font-size: 1.25rem;
  color: #01579b;
}

.navbar-setari-content {
  display: flex;
  align-items: center;
  height: 100%;
}

.navbar-setari .navbar-icon {
  width: auto;
  margin-right: 5px;
}

/* Dropdown Content Styles */
.dropdown-header {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #004d7a;
  margin-bottom: 15px;
  opacity: 0.6;
  padding: 0 10px;
}

.dropdown-link {
  padding: 12px 10px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  font-size: 14px;
  font-weight: 500;
  color: #01579b;
}

.dropdown-link i {
  margin-right: 12px;
  font-size: 1.2rem;
  width: 20px;
  text-align: center;
}

.dropdown-link:hover {
  background-color: rgba(255, 255, 255, 0.6);
  transform: translateX(5px);
  color: #004d7a;
}

.dropdown-link.text-danger {
  color: #c62828;
}

.dropdown-link.text-danger:hover {
  background-color: rgba(198, 40, 40, 0.05);
}

.dropdown-empty {
  padding: 30px 10px;
  text-align: center;
  font-size: 13px;
  color: #01579b;
  opacity: 0.5;
}

/* Dashboard Widgets */
.widget {
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 25px;
  box-shadow: rgba(100, 100, 111, 0.05) 0px 7px 29px 0px;
  transition: transform 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 160px;
}

.widget:hover {
  background: rgba(255, 255, 255, 0.5);
  box-shadow: rgba(100, 100, 111, 0.1) 0px 10px 40px 0px;
}

.widget-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.widget-icon {
  width: 42px;
  height: 42px;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #0b3d91;
  font-size: 1.4rem;
  box-shadow: rgba(0, 0, 0, 0.05) 0px 4px 12px;
}

.widget-title {
  font-size: 13px;
  font-weight: 700;
  color: #004d7a;
  opacity: 0.6;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin: 0;
}

.widget-main {
  margin-top: 15px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}

.widget-value {
  font-size: 32px;
  font-weight: 800;
  color: #0b3d91;
  margin: 0;
  letter-spacing: -1px;
}

.widget-trend {
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.widget-trend.up {
  background: rgba(76, 175, 80, 0.12);
  color: #1b5e20;
}

.widget-trend.down {
  background: rgba(244, 67, 54, 0.12);
  color: #b71c1c;
}

.btn-glass {
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 8px 16px;
    border-radius: 12px;
    color: #0b3d91;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(5px);
}

.btn-glass:hover {
    background: rgba(255, 255, 255, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.classic-module-wrapper {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 32px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 30px;
    box-shadow: rgba(100, 100, 111, 0.05) 0px 7px 29px 0px;
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-in {
    animation: fadeIn 0.4s ease-out;
}

/* --------------------------------------
   ANIMATIONS & TRANSITIONS
--------------------------------------- */

@keyframes revealUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes revealScale {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.animate-in-up {
    animation: revealUp 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.animate-in-scale {
    animation: revealScale 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

/* Staggered Delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }

/* Premium View Transitions - Dramatic Stagger */
.view-enter .widget, 
.view-enter .stat-pill,
.view-enter .dashboard-panel-financial,
.view-enter .welcome-left,
.view-enter .clients-container > *,
.view-enter .clients-main-grid > *,
.view-enter .dashboard-grid > *,
.view-enter .dashboard-main-row > * {
    opacity: 0;
    animation: revealUpSequential 0.8s cubic-bezier(0.2, 1, 0.2, 1) both;
}

/* Entry Stagger (0.15s steps for very clear sequential appearance) */
.view-enter *:nth-child(1) { animation-delay: 0.1s; }
.view-enter *:nth-child(2) { animation-delay: 0.25s; }
.view-enter *:nth-child(3) { animation-delay: 0.4s; }
.view-enter *:nth-child(4) { animation-delay: 0.55s; }
.view-enter *:nth-child(5) { animation-delay: 0.7s; }
.view-enter *:nth-child(6) { animation-delay: 0.85s; }
.view-enter *:nth-child(7) { animation-delay: 1.0s; }
.view-enter *:nth-child(8) { animation-delay: 1.15s; }
.view-enter *:nth-child(9) { animation-delay: 1.3s; }
.view-enter *:nth-child(10) { animation-delay: 1.45s; }

/* Exit Stagger (0.1s steps for sequential departure) */
.view-exit .widget, 
.view-exit .stat-pill,
.view-exit .dashboard-panel-financial,
.view-exit .welcome-left,
.view-exit > * {
    animation: revealDownSequential 0.5s cubic-bezier(0.4, 0, 1, 1) both !important;
}

.view-exit *:nth-child(1) { animation-delay: 0.0s; }
.view-exit *:nth-child(2) { animation-delay: 0.1s; }
.view-exit *:nth-child(3) { animation-delay: 0.2s; }
.view-exit *:nth-child(4) { animation-delay: 0.3s; }

@keyframes revealUpSequential {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.92);
        filter: blur(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

@keyframes revealDownSequential {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
    100% {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
        filter: blur(15px);
    }
}

/* Loading Overlay - Slimmer & Sleeker */
#content-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: transparent;
    z-index: 2000;
}

#content-loader .progress-bar {
    height: 100%;
    width: 0;
    background: #0b3d91;
    box-shadow: 0 0 10px rgba(11, 61, 145, 0.5);
    transition: width 0.3s ease;
}

/* --------------------------------------
   PRINT UTILITIES
--------------------------------------- */
@media print {
    .navbar, .header-actions, .btn-glass, .btn-primary-v2, .hr-tabs, .search-wrapper, .v2-modal-footer, .navbar-tab-indicator, .status-indicator {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    #main-content {
        margin-top: 0 !important;
        padding: 0 !important;
    }
    
    .widget, .hr-card-widget {
        box-shadow: none !important;
        border: none !important;
        background: white !important;
        padding: 0 !important;
    }

    .print-only {
        display: block !important;
    }

    .no-print {
        display: none !important;
    }
}

.print-only {
    display: none;
}

