/* BTS Project — BitChief brand theme (greens from the BTS logo) */
:root {
  --bts-primary: #067b3e;        /* logo dark green */
  --bts-primary-dark: #045c2e;
  --bts-primary-darker: #03421f;
  --bts-accent: #56b94b;         /* logo light-green stripe */
  --bts-primary-rgb: 6, 123, 62;
  --bts-sidebar-bg: #ffffff;     /* light sidebar — original logo sits on white */
  --bts-sidebar-hover: #eef6f0;
  --bts-sidebar-active-bg: #e2f2e7;
  --bts-sidebar-active: #067b3e;
  --bts-body-bg: #f4f7f5;
  --bts-border: #e3eae5;
}

/* Brand overrides for Bootstrap interactive elements */
.btn-primary {
  --bs-btn-bg: var(--bts-primary); --bs-btn-border-color: var(--bts-primary);
  --bs-btn-hover-bg: var(--bts-primary-dark); --bs-btn-hover-border-color: var(--bts-primary-dark);
  --bs-btn-active-bg: var(--bts-primary-darker); --bs-btn-active-border-color: var(--bts-primary-darker);
  --bs-btn-disabled-bg: var(--bts-primary); --bs-btn-disabled-border-color: var(--bts-primary);
}
.btn-outline-primary {
  --bs-btn-color: var(--bts-primary); --bs-btn-border-color: var(--bts-primary);
  --bs-btn-hover-bg: var(--bts-primary); --bs-btn-hover-border-color: var(--bts-primary);
  --bs-btn-active-bg: var(--bts-primary-dark); --bs-btn-active-border-color: var(--bts-primary-dark);
}
a { color: var(--bts-primary); }
a:hover { color: var(--bts-primary-dark); }
.text-primary { color: var(--bts-primary) !important; }
.form-check-input:checked { background-color: var(--bts-primary); border-color: var(--bts-primary); }
.form-control:focus, .form-select:focus {
  border-color: var(--bts-accent);
  box-shadow: 0 0 0 .25rem rgba(var(--bts-primary-rgb), .15);
}
.progress-bar { background-color: var(--bts-primary); }
.badge.text-bg-primary, .bg-primary { background-color: var(--bts-primary) !important; }
body { background: var(--bts-body-bg); font-size: .925rem; color: #263041; }
.bts-wrapper { display: flex; min-height: 100vh; }

/* Sidebar — light, original logo on white */
.bts-sidebar {
  width: 242px; min-width: 242px; background: var(--bts-sidebar-bg); color: #3c4b42;
  border-right: 1px solid var(--bts-border);
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto;
  scrollbar-width: thin; scrollbar-color: #c6d6cb transparent;
}
.bts-sidebar .brand {
  padding: 1.1rem 1.25rem 1rem; border-bottom: 1px solid var(--bts-border);
  text-decoration: none; display: block;
}
.bts-sidebar .brand img { height: 34px; width: auto; display: block; }
.bts-sidebar .brand .brand-sub {
  color: #7d9487; font-size: .66rem; text-transform: uppercase; letter-spacing: .13em;
  margin-top: .55rem;
}
.bts-sidebar .nav-link {
  color: #46564c; padding: .48rem 1.25rem; font-size: .885rem; border-left: 3px solid transparent;
  display: flex; align-items: center; gap: .15rem;
}
.bts-sidebar .nav-link:hover { background: var(--bts-sidebar-hover); color: var(--bts-primary-dark); text-decoration: none; }
.bts-sidebar .nav-link.active {
  background: var(--bts-sidebar-active-bg); color: var(--bts-primary-dark);
  border-left-color: var(--bts-sidebar-active); font-weight: 600;
}
.bts-sidebar .nav-heading {
  font-size: .68rem; text-transform: uppercase; letter-spacing: .09em; color: #93a89a; padding: .95rem 1.25rem .3rem;
}

/* Main area */
.bts-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.bts-topbar { background: #fff; border-bottom: 1px solid var(--bts-border); position: sticky; top: 0; z-index: 1020; }
.bts-content { padding: 1.25rem 1.5rem; flex: 1; }

/* Cards & tables */
.card { border: 1px solid var(--bts-border); box-shadow: 0 1px 2px rgba(16,24,40,.04); border-radius: .55rem; }
.card-header { background: #fff; font-weight: 600; border-bottom-color: var(--bts-border); border-radius: .55rem .55rem 0 0 !important; }
.card-footer { background: #fbfcfe; border-top-color: var(--bts-border); }
.table th { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: #667085; font-weight: 600; }
.table > :not(caption) > * > * { padding-top: .55rem; padding-bottom: .55rem; }
.table-hover > tbody > tr:hover > * { background-color: #f6f9fd; }

/* Badges */
.badge-status { text-transform: capitalize; font-weight: 500; }

/* Stat tiles */
.stat-card .value { font-size: 1.55rem; font-weight: 700; line-height: 1.15; }
.stat-card .label { color: #667085; font-size: .78rem; }

/* Avatar */
.avatar-sm {
  width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(135deg, var(--bts-accent), var(--bts-primary-dark)); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: .75rem; font-weight: 600; flex-shrink: 0;
}

/* Timeline */
.timeline { border-left: 2px solid var(--bts-border); margin-left: .75rem; padding-left: 1.25rem; }
.timeline-item { position: relative; padding-bottom: 1rem; }
.timeline-item::before {
  content: ""; position: absolute; left: -1.6rem; top: .3rem; width: 10px; height: 10px;
  border-radius: 50%; background: var(--bts-primary); box-shadow: 0 0 0 3px #d3ecd9;
}

.progress { height: 8px; border-radius: 6px; background-color: #eef1f6; }

/* Project tab nav */
.nav-tabs { border-bottom: 1px solid var(--bts-border); scrollbar-width: none; }
.nav-tabs::-webkit-scrollbar { display: none; }
.nav-tabs .nav-link { color: #5a6b60; border: 0; border-bottom: 2px solid transparent; padding: .5rem .85rem; font-size: .9rem; }
.nav-tabs .nav-link:hover { border-color: transparent; color: var(--bts-primary); text-decoration: none; }
.nav-tabs .nav-link.active { color: var(--bts-primary); background: transparent; border-bottom: 2px solid var(--bts-primary); font-weight: 600; }

/* Collapsible phase cards (Plan tab) */
.phase-card .collapse-toggle { user-select: none; }
.phase-card .collapse-toggle:hover { background: #f6f9fd; }
.phase-card .chevron { transition: transform .15s ease; color: #98a2b3; }
.phase-card .collapse-toggle[aria-expanded="true"] .chevron { transform: rotate(90deg); }

/* Pagination */
.pagination { margin-bottom: 0; --bs-pagination-padding-y: .25rem; --bs-pagination-padding-x: .6rem; --bs-pagination-font-size: .85rem; }
.pagination .page-link { color: #3c5c48; }
.pagination .page-item.active .page-link { background: var(--bts-primary); border-color: var(--bts-primary); }
/* Hide Laravel's verbose "Showing x to y" block on small screens */
@media (max-width: 575px) { .pagination-info, nav[role="navigation"] > div:first-child { display: none; } }

/* Forms */
.required::after { content: " *"; color: #dc3545; }
.form-label { font-weight: 500; margin-bottom: .3rem; }

/* Health dots */
.health-green { color: #198754; } .health-yellow { color: #f59f00; } .health-red { color: #dc3545; }

a { text-decoration: none; }
a:hover { text-decoration: underline; }
.min-w-0 { min-width: 0; }

/* ---- Auth pages ---- */
.auth-body {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1.5rem;
  background: linear-gradient(160deg, #f2f8f4 0%, #e8f3ec 50%, #ddeee3 100%);
  position: relative; overflow: hidden;
}
.auth-body::before, .auth-body::after {
  content: ""; position: absolute; border-radius: 50%; filter: blur(100px); opacity: .35;
}
.auth-body::before { width: 480px; height: 480px; background: #bfe4c9; top: -160px; right: -120px; }
.auth-body::after { width: 420px; height: 420px; background: #cdebd0; bottom: -160px; left: -120px; }
.auth-shell { position: relative; z-index: 1; width: 100%; max-width: 900px; }
.auth-card { border: 1px solid var(--bts-border); border-radius: 1rem; overflow: hidden; box-shadow: 0 20px 50px rgba(9,54,30,.12); }
.auth-brand-panel {
  background: #fbfdfb; border-right: 1px solid var(--bts-border); padding: 2.5rem 2.25rem;
  display: flex; flex-direction: column; justify-content: space-between; min-height: 100%;
}
.auth-brand-panel .brand-logo { height: 46px; width: auto; display: block; }
.auth-brand-panel .tagline { color: var(--bts-primary-dark); font-size: .9rem; margin-top: 1rem; font-weight: 600; }
.auth-brand-panel ul { list-style: none; padding: 0; margin: 1.5rem 0 0; }
.auth-brand-panel li { color: #51665a; font-size: .85rem; padding: .3rem 0; display: flex; gap: .5rem; align-items: start; }
.auth-brand-panel li i { color: var(--bts-primary); }
.auth-brand-panel .panel-footer { color: #8aa392; font-size: .78rem; }
.auth-form-panel { background: #fff; padding: 2.5rem 2.25rem; }
.auth-form-panel .form-control { padding: .6rem .8rem; }
.auth-form-panel .input-group-text { background: #f5faf6; color: #5f7568; }
.auth-simple-logo { background: #fff; border: 1px solid var(--bts-border); border-radius: .75rem; padding: .9rem 1.2rem; display: inline-block; box-shadow: 0 8px 24px rgba(9,54,30,.08); }
.auth-simple-logo img { height: 38px; width: auto; display: block; }
@media (max-width: 767px) { .auth-brand-panel { display: none; } .auth-shell { max-width: 430px; } }

/* Mobile sidebar */
@media (max-width: 991px) {
  .bts-sidebar { position: fixed; z-index: 1040; left: -242px; transition: left .2s; }
  .bts-sidebar.show { left: 0; }
  .bts-content { padding: 1rem; }
}
