/**
 * TEN Logistics Portal - Base Dashboard Stylesheet
 * Brand: trawler express network (TEN)
 */

:root {
  --ten-accent: #0d9ab0;
  --ten-navy: #003d5b;
  --ten-navy-dark: #002b42;
  --ten-bg: #f3f8fb;
  --ten-text: #0e2238;
  --ten-muted: #5e738e;
  --ten-border: #dbe7f0;
  --ten-card: #ffffff;
  --ten-radius: 10px;
  --ten-shadow: 0 4px 16px rgba(0, 48, 77, 0.06);
  --font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font);
  background: var(--ten-bg);
  color: var(--ten-text);
  font-size: 13px;
  -webkit-font-smoothing: antialiased;
}

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

button,
input,
select,
textarea {
  font-family: inherit;
}

button {
  cursor: pointer;
}

/* Application Layout */
.ten-app {
  min-height: 100vh;
  display: flex;
  background: linear-gradient(135deg, #f7fcfe 0%, #edf6fb 100%);
}

/* Sidebar Navigation */
.ten-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 190px;
  background: linear-gradient(180deg, #053b54 0%, #005473 60%, #01344e 100%);
  color: #fff;
  z-index: 100;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  transition: width 0.25s ease;
}

.ten-sidebar::-webkit-scrollbar {
  width: 4px;
}

.ten-sidebar::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.ten-sidebar:after {
  content: '';
  position: absolute;
  bottom: -110px;
  left: -80px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 0 35px rgba(255, 255, 255, 0.03), 0 0 0 70px rgba(255, 255, 255, 0.025);
  pointer-events: none;
}

.ten-sidebar-top {
  height: 50px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  position: relative;
  z-index: 2;
}

.sidebar-toggle {
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 20px;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: background 0.2s;
}

.sidebar-toggle:hover {
  background: rgba(255, 255, 255, 0.15);
}

.ten-mark {
  display: block;
  width: 44px;
  height: 44px;
}

.ten-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.ten-nav {
  padding: 14px 0;
  position: relative;
  z-index: 2;
  flex: 1;
}

.ten-nav-link {
  height: 44px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  color: #e6f5fa;
  font-size: 12px;
  font-weight: 600;
  position: relative;
  border-left: 4px solid transparent;
  transition: all 0.18s ease;
}

.ten-nav-link i {
  width: 20px;
  text-align: center;
  font-size: 15px;
  opacity: 0.85;
}

.ten-nav-link:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.ten-nav-link:hover i {
  opacity: 1;
}

.ten-nav-link.active {
  background: linear-gradient(90deg, #f59e0b, #d97706);
  border-left-color: #ffffff;
  color: #ffffff;
  font-weight: 700;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.2);
}

.ten-nav-link.active i {
  opacity: 1;
}

.ten-nav-link b {
  margin-left: auto;
  background: #ef4444;
  color: #fff;
  border-radius: 12px;
  padding: 2px 7px;
  font-size: 10px;
  font-weight: 800;
}

.ten-sidebar-quote {
  margin-top: auto;
  padding: 20px 18px 30px;
  color: #fde047;
  font-size: 11.5px;
  line-height: 1.5;
  position: relative;
  z-index: 2;
}

.ten-sidebar-quote strong {
  color: #ffffff;
}

.ten-sidebar-quote span {
  display: block;
  margin-top: 8px;
  width: 32px;
  height: 3px;
  background: #f59e0b;
  border-radius: 2px;
}

/* Main Content Area */
.ten-main {
  width: calc(100% - 190px);
  margin-left: 190px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  transition: all 0.25s ease;
}

/* Topbar Header */
.ten-topbar {
  height: 50px;
  background: #ffffff;
  border-bottom: 1px solid var(--ten-border);
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 0 24px;
  position: sticky;
  top: 0;
  z-index: 90;
  box-shadow: 0 2px 8px rgba(0, 36, 60, 0.03);
}

.ten-top-logo {
  width: 260px;
  flex: none;
}

.ten-top-logo img {
  width: 235px;
  max-width: 100%;
  height: auto;
  display: block;
}

.ten-search {
  height: 35px;
  border: 1px solid #d3e1ec;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  max-width: 400px;
  flex: 1;
  background: #f8fbfe;
  transition: all 0.2s;
}

.ten-search:focus-within {
  border-color: var(--ten-accent);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(13, 154, 176, 0.12);
}

.ten-search i {
  color: #64748b;
  font-size: 13px;
}

.ten-search input {
  border: 0;
  outline: 0;
  background: transparent;
  width: 100%;
  font-size: 12px;
  color: var(--ten-text);
}

.ten-search input::placeholder {
  color: #889bb2;
}

.ten-top-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 20px;
}

.icon-btn {
  position: relative;
  background: transparent;
  border: 0;
  color: #1e3a5f;
  font-size: 19px;
  padding: 6px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.icon-btn:hover {
  background: #f0f7fb;
  color: var(--ten-accent);
}

.icon-btn em {
  position: absolute;
  top: -2px;
  right: -2px;
  background: #ef4444;
  color: #fff;
  font-style: normal;
  font-size: 9px;
  font-weight: 800;
  min-width: 17px;
  height: 17px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 2px solid #ffffff;
}

.ten-user {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: background 0.2s;
}

.ten-user:hover {
  background: #f0f7fb;
}

.ten-user>span {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0d9ab0, #005473);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 12px;
  box-shadow: 0 2px 6px rgba(13, 154, 176, 0.25);
}

.ten-user div {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.ten-user strong {
  font-size: 12.5px;
  color: #0b2447;
}

.ten-user small {
  font-size: 10px;
  color: var(--ten-muted);
  font-weight: 500;
}

.ten-user>i {
  font-size: 10px;
  color: #7f94ab;
  margin-left: 2px;
}

/* Page Content Container */
.ten-content {
  padding: 5px 8px 5px;
  max-width: 1600px;
  width: 100%;
  margin: 0 auto;
}

/* Collapsed Sidebar Mode */
body.sidebar-collapsed .ten-sidebar {
  width: 68px;
}

body.sidebar-collapsed .ten-main {
  width: calc(100% - 68px);
  margin-left: 68px;
}

body.sidebar-collapsed .ten-mark,
body.sidebar-collapsed .ten-nav-link span,
body.sidebar-collapsed .ten-nav-link b,
body.sidebar-collapsed .ten-sidebar-quote {
  display: none !important;
}

body.sidebar-collapsed .ten-nav-link {
  justify-content: center;
  padding: 0;
}

body.sidebar-collapsed .ten-nav-link i {
  font-size: 18px;
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .ten-sidebar {
    width: 68px;
  }

  .ten-main {
    width: calc(100% - 68px);
    margin-left: 68px;
  }

  .ten-mark,
  .ten-nav-link span,
  .ten-nav-link b,
  .ten-sidebar-quote {
    display: none !important;
  }

  .ten-nav-link {
    justify-content: center;
    padding: 0;
  }

  .ten-topbar {
    padding: 0 14px;
    gap: 12px;
  }

  .ten-top-logo {
    width: 180px;
  }

  .ten-content {
    padding: 16px 14px;
  }
}