/* ==========================================================================
   Pink Attendance - Theme
   A soft pink & white design system layered on top of Bootstrap 5
   ========================================================================== */

:root {
    --pink-50: #fff5f9;
    --pink-100: #ffe6f0;
    --pink-200: #ffcbe1;
    --pink-300: #ffa5c9;
    --pink-400: #ff77b0;
    --pink-500: #ff4d94;
    --pink-600: #ec2f7b;
    --pink-700: #c81a63;
    --pink-800: #a11354;

    --ink: #2f1f2c;
    --ink-soft: #4a3545;
    --muted: #917f8d;
    --line: #f6e3ec;
    --white: #ffffff;
    --canvas: #fffafc;

    --grad-pink: linear-gradient(135deg, #ff4d94 0%, #ff7eb3 55%, #ffa5c9 100%);
    --grad-soft: linear-gradient(135deg, #fff0f6 0%, #ffe4ef 100%);
    --grad-deep: linear-gradient(135deg, #ff4d94 0%, #c81a63 100%);

    --shadow-xs: 0 1px 2px rgba(200, 26, 99, .06);
    --shadow-sm: 0 6px 18px rgba(200, 26, 99, .07);
    --shadow-md: 0 14px 34px rgba(200, 26, 99, .10);
    --shadow-lg: 0 26px 60px rgba(200, 26, 99, .16);

    --radius-sm: 12px;
    --radius: 18px;
    --radius-lg: 26px;
    --sidebar-w: 268px;

    --bs-primary: #ff4d94;
    --bs-primary-rgb: 255, 77, 148;
    --bs-link-color: #ec2f7b;
    --bs-link-hover-color: #c81a63;
    --bs-body-color: #2f1f2c;
    --bs-body-font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* {
    scrollbar-width: thin;
    scrollbar-color: var(--pink-200) transparent;
}

body {
    background-color: var(--canvas);
    color: var(--ink);
    font-family: var(--bs-body-font-family);
    font-size: .95rem;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    transition: color .18s ease;
}

h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
    font-weight: 700;
    letter-spacing: -.02em;
    color: var(--ink);
}

.text-muted, .text-secondary {
    color: var(--muted) !important;
}

.text-pink {
    color: var(--pink-600) !important;
}

.bg-soft-pink {
    background: var(--grad-soft) !important;
}

::selection {
    background: var(--pink-200);
    color: var(--pink-800);
}

/* --------------------------------------------------------------------------
   Brand
   -------------------------------------------------------------------------- */

.brand {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--ink);
}

.brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: var(--grad-pink);
    color: #fff;
    display: grid;
    place-items: center;
    font-size: 1.25rem;
    box-shadow: 0 8px 18px rgba(255, 77, 148, .35);
    flex: 0 0 auto;
}

.brand-mark-lg {
    width: 54px;
    height: 54px;
    border-radius: 18px;
    font-size: 1.6rem;
}

.brand-text small {
    display: block;
    font-size: .68rem;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--pink-500);
    line-height: 1.1;
}

.text-gradient {
    background: var(--grad-deep);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --------------------------------------------------------------------------
   App shell
   -------------------------------------------------------------------------- */

.app-shell {
    min-height: 100vh;
}

.app-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sidebar-w);
    background: var(--white);
    border-right: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    padding: 1.4rem 1.1rem;
    z-index: 1045;
    transition: transform .3s ease;
}

.app-main {
    margin-left: var(--sidebar-w);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.sidebar-brand {
    padding: .35rem .55rem 1.4rem;
}

.sidebar-nav-label {
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--muted);
    padding: 0 .75rem;
    margin: 1.1rem 0 .5rem;
}

.sidebar-nav {
    flex: 1 1 auto;
    overflow-y: auto;
    padding-bottom: 1rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: .8rem;
    padding: .72rem .85rem;
    border-radius: 14px;
    color: var(--ink-soft);
    font-weight: 600;
    font-size: .92rem;
    margin-bottom: .25rem;
    border: 1px solid transparent;
    transition: all .2s ease;
}

.sidebar-link i {
    font-size: 1.08rem;
    width: 22px;
    text-align: center;
    color: var(--muted);
    transition: color .2s ease;
}

.sidebar-link:hover {
    background: var(--pink-50);
    color: var(--pink-700);
}

.sidebar-link:hover i {
    color: var(--pink-500);
}

.sidebar-link.active {
    background: var(--grad-pink);
    color: #fff;
    box-shadow: 0 10px 22px rgba(255, 77, 148, .32);
}

.sidebar-link.active i {
    color: #fff;
}

.sidebar-footer {
    border-top: 1px solid var(--line);
    padding-top: .9rem;
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: .7rem;
    padding: .6rem;
    border-radius: 16px;
    background: var(--pink-50);
}

/* --------------------------------------------------------------------------
   Topbar
   -------------------------------------------------------------------------- */

.app-topbar {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: rgba(255, 255, 255, .88);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
    padding: .9rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.topbar-title h1 {
    font-size: 1.2rem;
    margin: 0;
    line-height: 1.2;
}

.topbar-title p {
    margin: .15rem 0 0;
    font-size: .8rem;
    color: var(--muted);
}

.app-content {
    padding: 1.6rem 1.5rem 3rem;
    flex: 1 1 auto;
}

/* --------------------------------------------------------------------------
   Cards
   -------------------------------------------------------------------------- */

.card-soft {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.card-soft > .card-header,
.card-soft > .card-footer {
    background: transparent;
    border-color: var(--line);
}

.card-header {
    padding: 1.05rem 1.25rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.card-body {
    padding: 1.25rem;
}

.card-hover {
    transition: transform .25s ease, box-shadow .25s ease;
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

/* --------------------------------------------------------------------------
   Stat cards
   -------------------------------------------------------------------------- */

.stat-card {
    position: relative;
    overflow: hidden;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 1.15rem 1.25rem;
    height: 100%;
    transition: transform .25s ease, box-shadow .25s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.stat-card::after {
    content: "";
    position: absolute;
    width: 120px;
    height: 120px;
    right: -45px;
    top: -55px;
    border-radius: 50%;
    background: var(--grad-soft);
    opacity: .85;
}

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    font-size: 1.3rem;
    color: #fff;
    position: relative;
    z-index: 1;
    flex: 0 0 auto;
}

.stat-label {
    font-size: .76rem;
    font-weight: 700;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: .2rem;
}

.stat-value {
    font-size: 1.7rem;
    font-weight: 800;
    line-height: 1.1;
    color: var(--ink);
}

.stat-note {
    font-size: .78rem;
    color: var(--muted);
}

/* gradient icon palettes */
.bg-grad-pink   { background: linear-gradient(135deg,#ff4d94,#ff7eb3); }
.bg-grad-plum   { background: linear-gradient(135deg,#c81a63,#ff4d94); }
.bg-grad-peach  { background: linear-gradient(135deg,#ff8a5b,#ffb199); }
.bg-grad-violet { background: linear-gradient(135deg,#8b5cf6,#c471f5); }
.bg-grad-sky    { background: linear-gradient(135deg,#38bdf8,#818cf8); }
.bg-grad-mint   { background: linear-gradient(135deg,#34d399,#6ee7b7); }
.bg-grad-amber  { background: linear-gradient(135deg,#fbbf24,#f97316); }
.bg-grad-rose   { background: linear-gradient(135deg,#f43f5e,#fb7185); }
.bg-grad-slate  { background: linear-gradient(135deg,#64748b,#94a3b8); }

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
    border-radius: 12px;
    font-weight: 600;
    padding: .55rem 1.1rem;
    border: 1px solid transparent;
    transition: all .2s ease;
}

.btn-sm {
    padding: .34rem .7rem;
    border-radius: 10px;
    font-size: .8rem;
}

.btn-lg {
    padding: .8rem 1.6rem;
    border-radius: 14px;
    font-size: 1rem;
}

.btn-pink {
    background: var(--grad-pink);
    color: #fff;
    box-shadow: 0 8px 20px rgba(255, 77, 148, .32);
}

.btn-pink:hover {
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(255, 77, 148, .4);
}

.btn-outline-pink {
    color: var(--pink-600);
    background: var(--white);
    border-color: var(--pink-200);
}

.btn-outline-pink:hover {
    background: var(--pink-50);
    border-color: var(--pink-400);
    color: var(--pink-700);
}

.btn-soft {
    background: var(--pink-50);
    color: var(--pink-700);
    border-color: transparent;
}

.btn-soft:hover {
    background: var(--pink-100);
    color: var(--pink-800);
}

.btn-white {
    background: #fff;
    color: var(--pink-700);
    box-shadow: var(--shadow-sm);
}

.btn-white:hover {
    color: var(--pink-800);
    transform: translateY(-2px);
}

/* big punch buttons on the employee dashboard */
.punch-btn {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--white);
    padding: 1.1rem;
    height: 100%;
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    gap: .9rem;
    box-shadow: var(--shadow-sm);
    transition: all .22s ease;
}

.punch-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--pink-200);
}

.punch-btn:disabled {
    opacity: .62;
    cursor: not-allowed;
}

.punch-icon {
    width: 50px;
    height: 50px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    font-size: 1.4rem;
    color: #fff;
    flex: 0 0 auto;
}

.punch-title {
    font-weight: 700;
    color: var(--ink);
    line-height: 1.2;
}

.punch-sub {
    font-size: .78rem;
    color: var(--muted);
}

/* --------------------------------------------------------------------------
   Forms
   -------------------------------------------------------------------------- */

.form-label {
    font-weight: 600;
    font-size: .82rem;
    color: var(--ink-soft);
    margin-bottom: .35rem;
}

.form-control, .form-select {
    border-radius: 12px;
    border-color: var(--line);
    padding: .6rem .9rem;
    font-size: .92rem;
    color: var(--ink);
    background-color: #fffdfe;
}

.form-control:focus, .form-select:focus {
    border-color: var(--pink-300);
    background-color: #fff;
    box-shadow: 0 0 0 .2rem rgba(255, 77, 148, .12);
}

.form-control::placeholder {
    color: #c3b2bd;
}

.form-control.is-invalid, .form-select.is-invalid {
    border-color: #fda4af;
}

.input-group-text {
    background: var(--pink-50);
    border-color: var(--line);
    color: var(--muted);
    border-radius: 12px;
}

.input-icon {
    position: relative;
}

.input-icon > i {
    position: absolute;
    left: .9rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--pink-400);
    z-index: 3;
    pointer-events: none;
}

.input-icon .form-control {
    padding-left: 2.6rem;
}

.form-hint {
    font-size: .78rem;
    color: var(--muted);
    margin-top: .3rem;
}

/* checkbox / radio in the pink style */
.form-check-input {
    border-color: var(--pink-200);
}

.form-check-input:checked {
    background-color: var(--pink-500);
    border-color: var(--pink-500);
}

.form-check-input:focus {
    box-shadow: 0 0 0 .2rem rgba(255, 77, 148, .14);
    border-color: var(--pink-400);
}

.form-check-label {
    font-size: .88rem;
    color: var(--ink-soft);
}

/* filter bar */
.filter-bar {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 1rem 1.15rem;
}

/* --------------------------------------------------------------------------
   Tables
   -------------------------------------------------------------------------- */

.table-card {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.table {
    --bs-table-bg: transparent;
    margin-bottom: 0;
    color: var(--ink);
}

.table > thead th {
    background: var(--pink-50);
    border-bottom: 1px solid var(--line);
    color: var(--pink-700);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .09em;
    text-transform: uppercase;
    padding: .85rem 1rem;
    white-space: nowrap;
}

.table > tbody td {
    padding: .85rem 1rem;
    vertical-align: middle;
    border-color: #faf0f5;
    font-size: .9rem;
}

.table > tbody tr:last-child td {
    border-bottom: 0;
}

.table > tbody tr {
    transition: background .16s ease;
}

.table > tbody tr:hover {
    background: #fffafc;
}

.table thead th:first-child,
.table tbody td:first-child {
    padding-left: 1.25rem;
}

.table thead th:last-child,
.table tbody td:last-child {
    padding-right: 1.25rem;
}

.table-actions {
    display: flex;
    gap: .35rem;
    justify-content: flex-end;
}

.icon-btn {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--ink-soft);
    display: grid;
    place-items: center;
    transition: all .18s ease;
    line-height: 1;
}

.icon-btn:hover {
    background: var(--pink-50);
    border-color: var(--pink-200);
    color: var(--pink-600);
}

.icon-btn.danger:hover {
    background: #fff1f3;
    border-color: #fecdd3;
    color: #e11d48;
}

/* --------------------------------------------------------------------------
   Badges & pills
   -------------------------------------------------------------------------- */

.badge {
    font-weight: 700;
    font-size: .72rem;
    letter-spacing: .03em;
    padding: .4rem .7rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: .35rem;
}

.badge-soft-success { background: #e7f9f0; color: #0f8a52; }
.badge-soft-warning { background: #fff4e0; color: #b4690e; }
.badge-soft-info    { background: #e4f4fe; color: #0369a1; }
.badge-soft-danger  { background: #ffe9ee; color: #be123c; }
.badge-soft-secondary{ background: #f1eefb; color: #6d4bb8; }
.badge-soft-dark    { background: #ece9f0; color: #4a3545; }
.badge-soft-primary { background: var(--pink-100); color: var(--pink-700); }

/* --------------------------------------------------------------------------
   Avatars
   -------------------------------------------------------------------------- */

.avatar {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    object-fit: cover;
    display: grid;
    place-items: center;
    color: #fff;
    font-weight: 700;
    font-size: .95rem;
    flex: 0 0 auto;
    box-shadow: 0 4px 12px rgba(200, 26, 99, .16);
}

.avatar-sm { width: 34px; height: 34px; border-radius: 11px; font-size: .8rem; }
.avatar-lg { width: 60px; height: 60px; border-radius: 20px; font-size: 1.3rem; }
.avatar-xl { width: 92px; height: 92px; border-radius: 28px; font-size: 2rem; }

.avatar-stack {
    display: flex;
}

.avatar-stack .avatar {
    margin-left: -12px;
    border: 3px solid #fff;
}

.avatar-stack .avatar:first-child {
    margin-left: 0;
}

.user-cell {
    display: flex;
    align-items: center;
    gap: .7rem;
    min-width: 0;
}

.user-cell-name {
    font-weight: 700;
    color: var(--ink);
    line-height: 1.25;
}

.user-cell-meta {
    font-size: .76rem;
    color: var(--muted);
}

/* --------------------------------------------------------------------------
   Timeline (punch card)
   -------------------------------------------------------------------------- */

.punch-hero {
    background: var(--grad-pink);
    border-radius: var(--radius-lg);
    color: #fff;
    padding: 1.6rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 18px 40px rgba(255, 77, 148, .3);
}

.punch-hero::before,
.punch-hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .16);
}

.punch-hero::before {
    width: 190px;
    height: 190px;
    right: -60px;
    top: -90px;
}

.punch-hero::after {
    width: 120px;
    height: 120px;
    right: 60px;
    bottom: -70px;
    background: rgba(255, 255, 255, .1);
}

.punch-hero > * {
    position: relative;
    z-index: 1;
}

.live-clock {
    font-size: 2.4rem;
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}

.timeline {
    position: relative;
    padding-left: 2.1rem;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 9px;
    top: 6px;
    bottom: 6px;
    width: 2px;
    background: var(--line);
}

.timeline-item {
    position: relative;
    padding-bottom: 1.15rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-dot {
    position: absolute;
    left: -2.1rem;
    top: 2px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--pink-200);
    display: grid;
    place-items: center;
}

.timeline-dot i {
    font-size: .55rem;
    color: var(--pink-500);
}

.timeline-dot.done {
    background: var(--grad-pink);
    border-color: transparent;
    box-shadow: 0 3px 8px rgba(255, 77, 148, .35);
}

.timeline-dot.done i {
    color: #fff;
}

.timeline-dot.active {
    border-color: var(--pink-500);
    box-shadow: 0 0 0 4px rgba(255, 77, 148, .14);
}

.timeline-title {
    font-weight: 700;
    font-size: .9rem;
    line-height: 1.3;
}

.timeline-time {
    font-size: .8rem;
    color: var(--muted);
}

/* --------------------------------------------------------------------------
   Calendar
   -------------------------------------------------------------------------- */

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
}

.cal-head {
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--pink-500);
    text-align: center;
    padding: .5rem 0;
}

.cal-day {
    aspect-ratio: 1 / 1;
    min-height: 58px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .15rem;
    font-size: .85rem;
    font-weight: 700;
    color: var(--ink-soft);
    position: relative;
    transition: all .18s ease;
}

.cal-day.blank {
    border: 0;
    background: transparent;
}

.cal-day:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.cal-day.today {
    outline: 2px solid var(--pink-500);
    outline-offset: -2px;
}

.cal-day.future {
    opacity: .5;
}

.cal-day i {
    font-size: .75rem;
    line-height: 1;
}

.cal-day.cal-present { background: #e7f9f0; border-color: #b7ecd3; color: #0f8a52; }
.cal-day.cal-late    { background: #fff4e0; border-color: #fbe0b0; color: #b4690e; }
.cal-day.cal-half_day{ background: #e4f4fe; border-color: #b3e0f8; color: #0369a1; }
.cal-day.cal-absent  { background: #ffe9ee; border-color: #fbc7d2; color: #be123c; }
.cal-day.cal-on_leave{ background: #f1eefb; border-color: #dbd0f7; color: #6d4bb8; }
.cal-day.cal-holiday { background: #ece9f0; border-color: #d8d2e0; color: #4a3545; }
.cal-day.cal-none    { color: #c3b2bd; font-weight: 600; }

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

/* --------------------------------------------------------------------------
   Monthly Attendance Grid
   -------------------------------------------------------------------------- */

.month-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--line);
    background: #fffafc;
}

.month-toolbar h5 {
    font-size: 1.05rem;
}

.month-scroll {
    max-height: 70vh;
    overflow: auto;
}

.month-table {
    width: max-content;
    min-width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.month-table > thead th {
    position: sticky;
    top: 0;
    z-index: 3;
    padding: .55rem .3rem;
    text-align: center;
    font-size: .68rem;
    letter-spacing: .04em;
    font-weight: 800;
}

.month-table > thead th.month-day-head {
    min-width: 42px;
}

.month-table > thead th.month-day-head.weekend {
    background: #f4f0f7;
    color: var(--muted);
}

.month-table > thead th.month-day-head.today {
    background: var(--pink-500);
    color: #fff;
}

.month-table > thead th.month-total-head {
    min-width: 44px;
    background: var(--pink-100);
}

.month-table > thead th.month-name-col {
    left: 0;
    z-index: 5;
    min-width: 210px;
    text-align: left;
}

.month-table > tbody td,
.month-table > tfoot td {
    padding: .35rem .3rem;
    text-align: center;
    font-size: .78rem;
}

.month-table > tbody td.month-name-col,
.month-table > tfoot td.month-name-col {
    position: sticky;
    left: 0;
    z-index: 2;
    min-width: 210px;
    text-align: left;
    background: var(--white);
    box-shadow: 1px 0 0 var(--line);
}

.month-table > tfoot td.month-name-col {
    z-index: 4;
    background: var(--pink-50);
    font-weight: 800;
    color: var(--pink-700);
    font-size: .78rem;
}

.month-cell {
    min-width: 42px;
}

.month-cell span {
    color: #d8c9d2;
}

.month-cell.future span {
    color: #e8dfe5;
}

.month-cell a {
    display: block;
    border-radius: 8px;
    padding: .15rem 0;
    font-weight: 800;
    font-size: .74rem;
    letter-spacing: .02em;
    text-decoration: none;
    color: inherit;
    transition: transform .14s ease, filter .14s ease;
}

.month-cell a:hover {
    transform: scale(1.12);
    filter: brightness(.95);
}

.month-table > tbody td.month-total {
    font-weight: 600;
    color: var(--ink-soft);
    min-width: 44px;
    border-left: 1px solid var(--line);
}

.month-table > tfoot td.month-total {
    background: var(--pink-50);
    color: var(--pink-700);
    border-left: 1px solid var(--line);
    font-size: .76rem;
}

/* --------------------------------------------------------------------------
   Progress
   -------------------------------------------------------------------------- */

.progress {
    height: 9px;
    border-radius: 999px;
    background: var(--pink-100);
}

.progress-bar {
    background: var(--grad-pink);
    border-radius: 999px;
}

.rate-ring {
    width: 128px;
    height: 128px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    margin: 0 auto;
    background: conic-gradient(var(--pink-500) calc(var(--rate, 0) * 1%), var(--pink-100) 0);
}

.rate-ring span {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: #fff;
    display: grid;
    place-items: center;
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--pink-600);
}

/* --------------------------------------------------------------------------
   Alerts & flash
   -------------------------------------------------------------------------- */

.alert {
    border: 1px solid transparent;
    border-radius: 14px;
    font-size: .9rem;
    padding: .8rem 1rem;
    display: flex;
    align-items: flex-start;
    gap: .6rem;
}

.alert-success { background: #e7f9f0; border-color: #b7ecd3; color: #0b6b41; }
.alert-danger  { background: #ffe9ee; border-color: #fbc7d2; color: #a31038; }
.alert-warning { background: #fff4e0; border-color: #fbe0b0; color: #92530a; }
.alert-info    { background: #e4f4fe; border-color: #b3e0f8; color: #075985; }

.toast-stack {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1080;
    width: min(380px, calc(100vw - 2rem));
    display: flex;
    flex-direction: column;
    gap: .6rem;
}

.toast-card {
    background: #fff;
    border: 1px solid var(--line);
    border-left: 4px solid var(--pink-500);
    border-radius: 14px;
    box-shadow: var(--shadow-lg);
    padding: .85rem 1rem;
    display: flex;
    align-items: flex-start;
    gap: .7rem;
    animation: toastIn .35s ease;
}

.toast-card.success { border-left-color: #10b981; }
.toast-card.error   { border-left-color: #f43f5e; }
.toast-card.warning { border-left-color: #f59e0b; }
.toast-card i { font-size: 1.15rem; }
.toast-card.success i { color: #10b981; }
.toast-card.error i   { color: #f43f5e; }
.toast-card.warning i { color: #f59e0b; }
.toast-card.info i    { color: var(--pink-500); }

@keyframes toastIn {
    from { opacity: 0; transform: translateX(24px); }
    to   { opacity: 1; transform: translateX(0); }
}

.invalid-feedback {
    font-size: .78rem;
    color: #e11d48;
}

/* --------------------------------------------------------------------------
   Auth & landing
   -------------------------------------------------------------------------- */

.auth-page {
    min-height: 100vh;
    display: flex;
    background: var(--canvas);
}

.auth-aside {
    flex: 0 0 46%;
    background: var(--grad-pink);
    color: #fff;
    padding: 3rem 3.2rem 3rem 4.2rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    position: relative;
    overflow: hidden;
}

.auth-aside::before,
.auth-aside::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .13);
}

.auth-aside::before {
    width: 380px;
    height: 380px;
    right: -140px;
    top: -110px;
}

.auth-aside::after {
    width: 280px;
    height: 280px;
    left: -110px;
    bottom: -90px;
    background: rgba(255, 255, 255, .1);
}

.auth-aside > * {
    position: relative;
    z-index: 1;
}

.auth-aside h2 {
    color: #fff;
    font-size: 2.1rem;
    line-height: 1.2;
    margin-top: 0;
}

/* The brand stays pinned to the top of the panel while the intro block below
   it takes the leftover space evenly, which centres it without moving the
   brand. Only the vertical distribution changes; nothing inside is restyled. */
.auth-aside > div {
    margin-top: auto;
    margin-bottom: auto;
}

.auth-aside .brand,
.auth-aside .brand-text small {
    color: #fff;
}

.auth-aside .brand-text small {
    opacity: .85;
}

.auth-feature {
    display: flex;
    gap: .9rem;
    align-items: flex-start;
    margin-bottom: 1.15rem;
}

.auth-feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: rgba(255, 255, 255, .2);
    display: grid;
    place-items: center;
    font-size: 1.2rem;
    flex: 0 0 auto;
    backdrop-filter: blur(4px);
}

.auth-feature h6 {
    color: #fff;
    margin: 0 0 .15rem;
    font-size: .95rem;
}

.auth-feature p {
    margin: 0;
    font-size: .84rem;
    opacity: .9;
}

.auth-main {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1.5rem;
    overflow-y: auto;
}

.auth-card {
    width: 100%;
    max-width: 460px;
}

.auth-title {
    font-size: 1.65rem;
    margin-bottom: .3rem;
}

.auth-sub {
    color: var(--muted);
    font-size: .92rem;
    margin-bottom: 1.6rem;
}

/* landing */
.landing-hero {
    background: var(--grad-pink);
    color: #fff;
    padding: 5rem 0 5.5rem;
    position: relative;
    overflow: hidden;
}

.landing-hero::before,
.landing-hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .12);
}

.landing-hero::before {
    width: 420px;
    height: 420px;
    right: -120px;
    top: -160px;
}

.landing-hero::after {
    width: 320px;
    height: 320px;
    left: -100px;
    bottom: -160px;
    background: rgba(255, 255, 255, .09);
}

.landing-hero > * {
    position: relative;
    z-index: 1;
}

.landing-hero h1 {
    color: #fff;
    font-size: 3rem;
    line-height: 1.12;
}

.feature-card {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.5rem;
    height: 100%;
    box-shadow: var(--shadow-sm);
    transition: transform .25s ease, box-shadow .25s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.feature-icon {
    width: 54px;
    height: 54px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    font-size: 1.4rem;
    color: #fff;
    margin-bottom: 1rem;
}

.nav-blur {
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}

/* --------------------------------------------------------------------------
   Empty state
   -------------------------------------------------------------------------- */

.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
}

.empty-icon {
    width: 84px;
    height: 84px;
    border-radius: 28px;
    background: var(--grad-soft);
    color: var(--pink-500);
    display: grid;
    place-items: center;
    font-size: 2.1rem;
    margin: 0 auto 1.1rem;
}

.empty-state h5 {
    margin-bottom: .35rem;
}

.empty-state p {
    color: var(--muted);
    font-size: .9rem;
    max-width: 380px;
    margin: 0 auto;
}

/* --------------------------------------------------------------------------
   Misc
   -------------------------------------------------------------------------- */

.soft-divider {
    height: 1px;
    background: var(--line);
    margin: 1.25rem 0;
    border: 0;
    opacity: 1;
}

.icon-tile {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: var(--pink-50);
    color: var(--pink-600);
    display: grid;
    place-items: center;
    font-size: 1.05rem;
    flex: 0 0 auto;
}

.chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}

.chip {
    font-size: .76rem;
    font-weight: 600;
    color: var(--ink-soft);
    background: var(--pink-50);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: .3rem .7rem;
}

.mono {
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.chart-box {
    position: relative;
    height: 260px;
}

.chart-box-sm {
    height: 210px;
}

.mini-bar {
    height: 7px;
    border-radius: 999px;
    background: var(--pink-100);
    overflow: hidden;
}

.mini-bar span {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: var(--grad-pink);
}

.list-row {
    display: flex;
    align-items: center;
    gap: .8rem;
    padding: .8rem 0;
    border-bottom: 1px solid var(--line);
}

.list-row:last-child {
    border-bottom: 0;
}

.rank-badge {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    font-weight: 800;
    font-size: .82rem;
    background: var(--pink-50);
    color: var(--pink-600);
    flex: 0 0 auto;
}

.rank-badge.top {
    background: var(--grad-pink);
    color: #fff;
    box-shadow: 0 6px 14px rgba(255, 77, 148, .3);
}

.sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(47, 31, 44, .45);
    backdrop-filter: blur(2px);
    z-index: 1040;
    display: none;
}

.sidebar-backdrop.show {
    display: block;
}

.pagination {
    gap: .3rem;
}

.page-link {
    border-radius: 10px;
    border-color: var(--line);
    color: var(--ink-soft);
    font-size: .86rem;
    padding: .42rem .75rem;
}

.page-link:hover {
    background: var(--pink-50);
    border-color: var(--pink-200);
    color: var(--pink-700);
}

.page-item.active .page-link {
    background: var(--grad-pink);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 6px 14px rgba(255, 77, 148, .28);
}

.page-item.disabled .page-link {
    color: #c3b2bd;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1199.98px) {
    .app-sidebar {
        transform: translateX(-100%);
        box-shadow: var(--shadow-lg);
    }

    .app-sidebar.open {
        transform: translateX(0);
    }

    .app-main {
        margin-left: 0;
    }
}

@media (max-width: 991.98px) {
    .auth-aside {
        display: none;
    }

    .landing-hero h1 {
        font-size: 2.3rem;
    }

    .app-content {
        padding: 1.15rem 1rem 2.5rem;
    }
}

@media (max-width: 575.98px) {
    .stat-value {
        font-size: 1.45rem;
    }

    .live-clock {
        font-size: 1.9rem;
    }

    .punch-hero {
        padding: 1.25rem;
    }

    .toast-stack {
        left: 1rem;
        right: 1rem;
        width: auto;
    }
}
