/* Header Component */
.header {
  height: 96px;
  background-color: var(--bg-main);
  display: flex;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 100;
  padding-right: var(--space-6);
}

/* Dark Logo Area */
.header-logo-area {
  background-color: #32140E;
  height: 100%;
  width: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom-right-radius: 50px;
  margin-right: var(--space-6);
  box-shadow: 4px 0 12px rgba(50, 20, 14, 0.1);
}

.header-logo-mask {
  height: 80px;
  width: 220px;
  background-color: var(--bg-main); /* Krem tek renk */
  -webkit-mask-image: url('../../assets/images/reva%20vela_%202.png');
  -webkit-mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-image: url('../../assets/images/reva%20vela_%202.png');
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
}

/* Left Middle: Welcome Box */
.header-welcome-box {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #FFFFFF;
  border: 1px solid rgba(155, 106, 70, 0.12);
  box-shadow: 0 8px 24px rgba(50, 30, 20, 0.04);
  padding: 6px 16px 6px 6px;
  border-radius: 18px;
}
.welcome-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #FFF9F2;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(155, 106, 70, 0.1);
}
.welcome-text-col {
  display: flex;
  flex-direction: column;
}
.welcome-greeting {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 500;
  color: #766A63;
  margin-bottom: 2px;
  letter-spacing: 0.2px;
}
.welcome-role {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  color: #1A110E;
  letter-spacing: -0.3px;
  line-height: 1;
}

/* Center: Navigation (Segmented Control) */
.header-segmented-nav {
  display: flex;
  align-items: center;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  background: #EAE0D5;
  padding: 4px;
  border-radius: 999px;
  gap: 4px;
}
.segment-bg {
  position: absolute;
  top: 4px;
  left: 4px;
  height: calc(100% - 8px);
  background-color: #FFFFFF;
  border-radius: 999px;
  box-shadow: 0 2px 12px rgba(50, 30, 20, 0.06);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1;
}
.nav-segment {
  padding: 8px 24px;
  border-radius: 999px;
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease;
  color: rgba(36, 23, 19, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  outline: none !important;
  z-index: 2;
  position: relative;
  -webkit-tap-highlight-color: transparent;
}
.nav-segment:focus {
  outline: none !important;
}
.nav-segment.active {
  color: #241713;
}
.nav-segment:not(.active):hover {
  color: #241713;
}
.nav-pill:not(.active):hover {
  background-color: rgba(155, 106, 70, 0.05);
  border-color: rgba(155, 106, 70, 0.4);
}
.nav-chevron {
  width: 14px;
  color: #9B6A46;
}

/* Right: User/Date (Control Island) */
.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: auto;
  background: #FFFFFF;
  border: 1px solid rgba(155, 106, 70, 0.12);
  box-shadow: 0 8px 24px rgba(50, 30, 20, 0.04);
  padding: 6px 8px 6px 24px;
  border-radius: 18px;
}
.header-date-area {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-right: 16px;
  border-right: 1.5px solid rgba(155, 106, 70, 0.12);
  background: transparent;
}
.date-icon {
  width: 18px;
  color: #9B6A46;
}
.date-text-col {
  display: flex;
  flex-direction: column;
}
.date-text {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  color: #241713;
  letter-spacing: -0.3px;
}
.time-text {
  font-size: 12.5px;
  font-weight: 400;
  color: rgba(36, 23, 19, 0.6);
  margin-top: 1px;
}
.weekday-text {
  font-weight: 700;
  color: #241713;
}

.header-notification {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: transparent;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  color: #9B6A46; /* Changed from black-ish to brand color */
  transition: background-color 0.2s ease;
}
.header-notification:hover {
  background-color: rgba(155, 106, 70, 0.06);
}
.notification-dot {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 8px;
  height: 8px;
  background-color: #D64545;
  border-radius: 50%;
  border: 2px solid #FFFFFF;
}

.header-profile-dropdown {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  background-color: rgba(155, 106, 70, 0.04);
  border-radius: 50%;
  transition: background-color 0.2s ease;
}
.header-profile-dropdown:hover {
  background-color: rgba(155, 106, 70, 0.08);
}
.header-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #9B6A46 0%, #784A2A 100%); /* Brand brown gradient instead of black */
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(50, 30, 20, 0.15);
}
.profile-name {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: #241713;
  letter-spacing: -0.3px;
}
.profile-chevron {
  width: 14px;
  color: #9B6A46;
}

/* Dashboard Layout */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-template-rows: auto auto minmax(0, 1fr);
  height: calc(100vh - 128px);
  gap: 19px;
  padding-top: 14px;
  max-width: 1440px;
  margin: 0 auto;
}

/* Dashboard Layout Components */
.dashboard-top-row {
  grid-column: span 12;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 19px;
  align-items: stretch;
}

.dashboard-hero {
  border-radius: var(--radius-card);
  padding: 23px 24px 14px 24px; /* Reduced bottom by 7px, integrated top 23px */
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  position: relative;
  overflow: hidden;
  height: 100%;
  background-color: #32140E;
  background-image: linear-gradient(to right, rgba(26, 10, 7, 0.95) 0%, rgba(26, 10, 7, 0.7) 45%, rgba(26, 10, 7, 0.1) 100%), url('../../assets/images/qrmenuarkaplan_banner1.png');
  background-size: cover;
  background-position: center right;
  background-repeat: no-repeat;
}

.dashboard-quick-actions-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 16px 24px 19px 24px; /* Reduced bottom by 7px (from 26px) */
  height: 100%;
}

.qa-header {
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

.qa-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
  transform: translateY(-8px);
}

.qa-action-card {
  display: flex;
  align-items: center;
  background-color: #FFFFFF;
  border-radius: 12px;
  height: 52px;
  padding: 0 16px;
  cursor: pointer;
  transition: all 0.25s ease;
  border: 1px solid rgba(155, 106, 70, 0.15);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.qa-action-card:hover {
  background-color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(155, 106, 70, 0.08);
  border-color: rgba(155, 106, 70, 0.25);
}

.qa-icon {
  width: 22px;
  height: 22px;
  color: #9B6A46;
  stroke-width: 2px;
}

.qa-label {
  flex: 1;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 700;
  color: #241713;
  margin-left: 12px;
  line-height: 1.2;
}

.qa-chevron {
  width: 14px;
  color: #9B6A46;
  opacity: 0.6;
  flex-shrink: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.qa-action-card:hover .qa-chevron {
  transform: translateX(4px);
  opacity: 1;
}

/* KPI Cards */
.kpi-row {
  grid-column: span 12;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 19px;
}

.kpi-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  padding: 14px 16px;
  gap: 16px;
}

.kpi-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #EAE0D5;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #32140E;
  flex-shrink: 0;
}

.kpi-icon svg {
  width: 24px;
  height: 24px;
  stroke-width: 2px;
}

.kpi-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.kpi-title {
  font-size: 11.5px;
  font-weight: 700;
  color: #8C7C72;
  margin-bottom: 2px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kpi-value {
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 800;
  line-height: 1;
  color: #241713;
  letter-spacing: -1px;
}

/* Section Grid */
.section-grid {
  grid-column: span 12;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 19px;
}

/* Menu Control List */
.menu-control-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.menu-control-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-3) var(--space-4);
  background: var(--bg-main);
  border-radius: var(--radius-btn);
  border: 1px solid var(--border-color);
  cursor: pointer;
  transition: background-color 0.2s;
}
.menu-control-item:hover {
  background: var(--bg-secondary);
}

/* Products Table */
.table-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-card);
  overflow: hidden;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th {
  background: var(--bg-secondary);
  text-align: left;
  padding: var(--space-4);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
}

.table td {
  padding: var(--space-4);
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.table tr:last-child td {
  border-bottom: none;
}

.table tr:hover td {
  background-color: var(--bg-main);
}

/* Premium Dashboard Lists */
.premium-list-item {
  padding: 8px 12px;
  margin: 0 -12px;
  border-radius: 12px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  border-bottom: none !important;
}

.premium-list-item:hover {
  background: #F9F6F0;
  transform: translateX(4px);
}

/* Input Fields */
.input {
  width: 100%;
  padding: 10px var(--space-3);
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--text-primary);
  outline: none;
  transition: all 0.2s ease;
}

.input:focus {
  border-color: var(--color-gold);
  box-shadow: 0 0 0 2px rgba(181, 139, 85, 0.2);
}

/* Responsive */
@media (max-width: 1024px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .dashboard-hero, .dashboard-quick-actions, .kpi-row, .section-grid {
    grid-column: span 1;
  }
  .kpi-row {
    grid-template-columns: repeat(2, 1fr);
  }
  .section-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .kpi-row {
    grid-template-columns: 1fr;
  }
  .header-date, .header-profile span {
    display: none;
  }
}

/* ==========================================================================
   Dashboard Utilities & Extracted Styles
   ========================================================================== */

.mt-4 {
  margin-top: var(--space-4);
}

.hero-content {
  max-width: 65%;
  position: relative;
  z-index: 2;
}

.hero-subtitle {
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: 4px;
  margin-bottom: 8px;
  color: #D9CEC2;
}

.hero-title {
  margin-bottom: 4px;
  color: #FFF9F2;
}

.hero-desc {
  margin-bottom: 8px;
  color: rgba(255, 249, 242, 0.85);
}

.hero-btn {
  background-color: #EAE0D5;
  color: #241713;
  border-radius: 12px;
  padding: 10px 18px;
  font-weight: 600;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: none;
  text-decoration: none;
  transition: all 0.2s ease;
  margin-top: 8px;
}
.hero-btn:hover {
  background-color: #D9CEC2;
  transform: translateY(-1px);
}

.status-icon-success {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--status-success);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
}

@keyframes drawSlice {
  from { stroke-dasharray: 0 var(--circ); }
  to { stroke-dasharray: var(--dash) var(--circ); }
}


/* Premium Hourglass Loader */
.hourglass-loader {
  display: inline-block;
  width: 32px;
  height: 32px;
  position: relative;
  animation: hourglass-flip 2s infinite ease-in-out;
}

.hourglass-loader::before,
.hourglass-loader::after {
  content: "";
  position: absolute;
  width: 0;
  height: 0;
  border-left: 16px solid transparent;
  border-right: 16px solid transparent;
}

.hourglass-loader::before {
  top: 0;
  border-top: 16px solid #9B6A46;
  border-bottom: 0;
  transform-origin: bottom center;
  animation: hourglass-sand-top 2s infinite ease-in-out;
}

.hourglass-loader::after {
  bottom: 0;
  border-bottom: 16px solid #9B6A46;
  border-top: 0;
  transform-origin: top center;
  animation: hourglass-sand-bottom 2s infinite ease-in-out;
}

@keyframes hourglass-flip {
  0%, 40% { transform: rotate(0); }
  60%, 100% { transform: rotate(180deg); }
}

@keyframes hourglass-sand-top {
  0% { transform: scale(1); }
  40%, 100% { transform: scale(0); }
}

@keyframes hourglass-sand-bottom {
  0% { transform: scale(0); }
  40%, 100% { transform: scale(1); }
}


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