/* Fonts are served from this site (Sansation, SIL Open Font License) so visitors' browsers never contact Google. */
@font-face { font-family: 'Sansation'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('../fonts/sansation-400.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Sansation'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('../fonts/sansation-700.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ==========================================================================
   Digital Shed apps - shared look and feel
   (identical in the Monitor, Invite and Invoice repos)
   ========================================================================== */

:root {
    --ds-navy: #0a2944;
    --ds-navy-2: #123f68;
    --ds-blue: #2576ad;
    --ds-accent: #3be0c3;      /* mint: selected page, glows */
    --ds-ink: #14283c;
    --ds-muted: #6b7c8d;
    --ds-line: #dde6ee;
    --ds-radius: 16px;
    --ds-shadow: 0 10px 30px rgba(10, 41, 68, .18);
    --ds-shadow-lg: 0 18px 44px rgba(10, 41, 68, .28);
}

body {
    margin: 0;
    font-family: "Sansation", Arial, sans-serif;
    font-weight: 400;
    color: var(--ds-ink);
    background: #e9f0f6 url('../images/bg.jpg') no-repeat center center fixed;
    background-size: cover;
    min-height: 100vh;
}
b, strong { font-weight: 700; }
a { color: var(--ds-blue); }

/* --------------------------------------------------------------------------
   Navigation: thick bar, icon over label, lift + tint on hover, glowing tile
   for the page you are on.
   -------------------------------------------------------------------------- */
.ds-nav {
    background: linear-gradient(180deg, var(--ds-navy-2) 0%, var(--ds-navy) 100%);
    border-bottom: 3px solid var(--ds-accent);
    box-shadow: 0 5px 20px -4px rgba(59, 224, 195, .45), 0 10px 30px rgba(5, 20, 36, .4);
    padding: .45rem 0 .6rem;
    margin-bottom: 1.75rem;
}
.ds-nav .navbar-brand img { max-height: 48px; transition: transform .25s ease; }
.ds-nav .navbar-brand:hover img { transform: scale(1.04); }
.ds-nav .navbar-toggler { border: 1px solid rgba(255, 255, 255, .35); border-radius: 10px; padding: .45rem .65rem; }
.ds-nav .navbar-nav { gap: .3rem; align-items: stretch; }

.ds-nav .nav-link {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    min-width: 88px;
    padding: .8rem 1.15rem !important;
    border: 1px solid transparent;
    border-radius: 14px;
    background: transparent;
    color: rgba(255, 255, 255, .8) !important;
    font-family: inherit;
    font-size: .85rem;
    font-weight: 700;
    letter-spacing: .02em;
    line-height: 1;
    cursor: pointer;
    transition: transform .2s ease, background-color .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.ds-nav .nav-link i {
    font-size: 1.7rem;
    line-height: 1;
    transition: transform .2s ease;
}
.ds-nav .nav-link:hover,
.ds-nav .nav-link:focus-visible {
    background: rgba(255, 255, 255, .11);
    border-color: rgba(255, 255, 255, .14);
    color: #fff !important;
    transform: translateY(-3px);
    outline: none;
}
.ds-nav .nav-link:hover i,
.ds-nav .nav-link:focus-visible i { transform: scale(1.12); }

.ds-nav .nav-link.active {
    background: rgba(59, 224, 195, .13);
    border-color: rgba(59, 224, 195, .5);
    color: var(--ds-accent) !important;
    box-shadow: 0 0 24px rgba(59, 224, 195, .2), inset 0 0 0 1px rgba(59, 224, 195, .1);
}
.ds-nav .nav-link.active::after {            /* glowing underline sitting on the bar's edge */
    content: "";
    position: absolute;
    left: 20%;
    right: 20%;
    bottom: -.72rem;
    height: 3px;
    border-radius: 3px;
    background: var(--ds-accent);
    box-shadow: 0 0 12px 1px var(--ds-accent);
}
.ds-nav form { margin: 0; display: flex; }
.ds-nav form .nav-link { width: 100%; }

@media (max-width: 991.98px) {
    .ds-nav .navbar-collapse { padding: .75rem 0 .25rem; }
    .ds-nav .navbar-nav { gap: .35rem; }
    .ds-nav .nav-link {
        flex-direction: row;
        justify-content: flex-start;
        gap: .9rem;
        padding: .75rem 1rem !important;
        font-size: 1rem;
    }
    .ds-nav .nav-link i { font-size: 1.35rem; }
    .ds-nav .nav-link:hover, .ds-nav .nav-link:focus-visible { transform: translateX(4px); }
    .ds-nav .nav-link.active::after { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    .ds-nav .nav-link, .ds-nav .nav-link i, .btn, .ds-lift { transition: none !important; }
    .ds-nav .nav-link:hover, .ds-nav .nav-link:focus-visible { transform: none; }
}

/* --------------------------------------------------------------------------
   Cards, buttons, forms, tables, alerts
   -------------------------------------------------------------------------- */
.card {
    border: 0;
    border-radius: var(--ds-radius);
    box-shadow: var(--ds-shadow);
    overflow: hidden;
}
.card-header {
    background: linear-gradient(135deg, var(--ds-navy-2), var(--ds-navy));
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
    padding: .95rem 1.25rem;
    border: 0;
}
.card-header .btn-light { font-size: .8rem; }
.card-footer { background: #f6f9fc; border-top: 1px solid var(--ds-line); }

.btn {
    border-radius: 10px;
    font-weight: 700;
    transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease, color .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primary {
    background: linear-gradient(135deg, var(--ds-blue), var(--ds-navy));
    border: 0;
    box-shadow: 0 4px 14px rgba(37, 118, 173, .35);
}
.btn-primary:hover, .btn-primary:focus {
    background: linear-gradient(135deg, #2e86c2, var(--ds-navy-2));
    box-shadow: 0 8px 20px rgba(37, 118, 173, .45);
}
.btn-success { box-shadow: 0 4px 14px rgba(25, 135, 84, .3); }
.btn-sm { border-radius: 8px; }
.btn-icon { width: 2.1rem; height: 2.1rem; padding: 0; display: inline-flex; align-items: center; justify-content: center; }

.form-label { font-weight: 700; font-size: .88rem; color: var(--ds-navy); margin-bottom: .35rem; }
.form-control, .form-select {
    border-radius: 10px;
    border: 1px solid #c8d5e2;
    padding: .62rem .85rem;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.form-control:focus, .form-select:focus {
    border-color: var(--ds-blue);
    box-shadow: 0 0 0 .22rem rgba(37, 118, 173, .18);
}
h5.text-primary { color: var(--ds-blue) !important; font-weight: 700; }

.table { --bs-table-hover-bg: rgba(37, 118, 173, .06); }
.table > thead > tr > th {
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .07em;
    color: var(--ds-muted);
    font-weight: 700;
    border-bottom: 1px solid var(--ds-line);
    background: #f6f9fc;
    padding: .8rem 1rem;
}
.table > tbody > tr > td { padding: .85rem 1rem; vertical-align: middle; }
@media (max-width: 575.98px) {
    .table-responsive .table > :not(caption) > * > * { white-space: nowrap; }
}
.badge { font-weight: 700; letter-spacing: .03em; padding: .45em .75em; border-radius: 999px; }

.alert {
    border: 0;
    border-left: 5px solid;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, .1);
    display: flex;
    gap: .7rem;
    align-items: flex-start;
}
.alert > i { font-size: 1.15rem; line-height: 1.4; }
.alert-success { border-left-color: #1f9d6b; }
.alert-danger  { border-left-color: #d6334a; }

/* Page header strip */
.ds-page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .75rem 1rem;
    margin-bottom: 1.25rem;
    padding: 1rem 1.35rem;
    border-radius: var(--ds-radius);
    background: rgba(10, 41, 68, .82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: #fff;
    box-shadow: var(--ds-shadow);
}
.ds-page-head h1 { font-size: 1.5rem; margin: 0; font-weight: 700; }
.ds-page-head h1 i { color: var(--ds-accent); margin-right: .5rem; }
.ds-page-head .sub { color: rgba(255, 255, 255, .75); font-size: .9rem; }

.ds-footer {
    width: fit-content;
    max-width: calc(100% - 2rem);
    margin: 2.5rem auto 2.5rem;
    padding: .65rem 1.4rem;
    border-radius: 999px;
    text-align: center;
    font-size: .85rem;
    color: rgba(255, 255, 255, .92);
    background: rgba(10, 41, 68, .84); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    box-shadow: var(--ds-shadow);
}
.ds-footer a { color: var(--ds-accent); font-weight: 700; text-decoration: none; }
.ds-footer a:hover { text-decoration: underline; }

/* --------------------------------------------------------------------------
   Sign in / sign up cards
   -------------------------------------------------------------------------- */
.ds-auth .card-header { text-align: center; font-size: 1.25rem; padding: 1.2rem; }
.ds-auth .card-header i { color: var(--ds-accent); margin-right: .5rem; }

/* --------------------------------------------------------------------------
   FAQ pages
   -------------------------------------------------------------------------- */
.ds-hero {
    text-align: center;
    padding: 2.25rem 1.5rem;
    margin-bottom: 1.75rem;
    border-radius: 22px;
    color: #fff;
    background: linear-gradient(135deg, rgba(18, 63, 104, .93), rgba(10, 41, 68, .93));
    box-shadow: var(--ds-shadow-lg);
}
.ds-hero .ds-hero-icon {
    width: 68px; height: 68px;
    margin: 0 auto 1rem;
    border-radius: 20px;
    display: grid; place-items: center;
    font-size: 2rem;
    color: var(--ds-navy);
    background: var(--ds-accent);
    box-shadow: 0 0 28px rgba(59, 224, 195, .55);
}
.ds-hero h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); font-weight: 700; margin-bottom: .4rem; }
.ds-hero p { color: rgba(255, 255, 255, .85); font-size: 1.1rem; margin: 0; }

.ds-section-title {
    display: inline-flex;
    align-items: center;
    margin: 2rem 0 .9rem;
    padding: .5rem 1.1rem;
    border-radius: 999px;
    color: #fff;
    font-weight: 700;
    font-size: 1.05rem;
    background: rgba(10, 41, 68, .84); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    box-shadow: var(--ds-shadow);
}
.ds-section-title i { color: var(--ds-accent); margin-right: .5rem; }

.ds-steps { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 576px) { .ds-steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 992px) { .ds-steps { grid-template-columns: repeat(4, 1fr); } }
.ds-step {
    position: relative;
    background: #fff;
    border-radius: var(--ds-radius);
    padding: 1.4rem 1.2rem 1.2rem;
    box-shadow: var(--ds-shadow);
    transition: transform .2s ease, box-shadow .2s ease;
}
.ds-step:hover { transform: translateY(-4px); box-shadow: var(--ds-shadow-lg); }
.ds-step .num {
    width: 38px; height: 38px;
    border-radius: 12px;
    display: grid; place-items: center;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, var(--ds-blue), var(--ds-navy));
    margin-bottom: .8rem;
}
.ds-step h3 { font-size: 1.02rem; font-weight: 700; color: var(--ds-navy); margin-bottom: .35rem; }
.ds-step p { margin: 0; color: var(--ds-muted); font-size: .9rem; line-height: 1.5; }

.ds-example { background: #fff; border-radius: var(--ds-radius); padding: .6rem; box-shadow: var(--ds-shadow); }
.ds-example img { border-radius: 12px; width: 100%; height: auto; display: block; }
.ds-example small { display: block; padding: .6rem .4rem .2rem; color: var(--ds-muted); text-align: center; }

.ds-accordion .accordion-item {
    border: 0;
    border-radius: var(--ds-radius) !important;
    margin-bottom: .8rem;
    overflow: hidden;
    box-shadow: var(--ds-shadow);
}
.ds-accordion .accordion-button {
    font-weight: 700;
    color: var(--ds-navy);
    padding: 1.1rem 1.3rem;
    gap: .75rem;
    box-shadow: none;
}
.ds-accordion .accordion-button i { color: var(--ds-blue); font-size: 1.25rem; }
.ds-accordion .accordion-button:not(.collapsed) { background: rgba(37, 118, 173, .09); color: var(--ds-navy); }
.ds-accordion .accordion-button:focus { box-shadow: 0 0 0 .2rem rgba(37, 118, 173, .2); }
.ds-accordion .accordion-body { padding: 1.2rem 1.4rem 1.4rem; line-height: 1.6; }
.ds-accordion .accordion-body ul { margin: 0; padding-left: 1.2rem; }
.ds-accordion .accordion-body li { margin-bottom: .5rem; }

.ds-cta {
    text-align: center;
    margin: 2.25rem 0 1rem;
    padding: 1.5rem 1rem;
    border-radius: 20px;
    color: #fff;
    background: rgba(10, 41, 68, .84); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    box-shadow: var(--ds-shadow);
}
.ds-cta p { margin-bottom: .8rem; font-size: 1.1rem; }
/* the page's normal navy button vanishes on the dark panel, so use the bright accent here */
.ds-cta .btn-primary {
    background: var(--ds-accent);
    color: var(--ds-navy);
    box-shadow: 0 0 22px rgba(59, 224, 195, .45);
}
.ds-cta .btn-primary:hover, .ds-cta .btn-primary:focus {
    background: #6df0d8;
    color: var(--ds-navy);
    box-shadow: 0 0 30px rgba(59, 224, 195, .65);
}

/* ==========================================================================
   Shared components: stat tiles, status pills, dots, empty states
   ========================================================================== */
.stat-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: .9rem; margin-bottom: 1.25rem; }
.stat-tile { background: #fff; border-radius: var(--ds-radius); padding: 1rem 1.1rem; box-shadow: var(--ds-shadow); display: flex; align-items: center; gap: .85rem; }
.stat-tile .ico { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; font-size: 1.4rem; flex: none; }
.stat-tile .n { font-size: 1.6rem; font-weight: 700; line-height: 1; color: var(--ds-navy); }
.stat-tile .l { font-size: .78rem; color: var(--ds-muted); text-transform: uppercase; letter-spacing: .06em; }
.ico.all { background: #e3eefa; color: var(--ds-blue); }
.ico.yes { background: #dff5ea; color: #1f9d6b; }
.ico.no { background: #fde4e8; color: #d6334a; }
.ico.wait { background: #eef1f5; color: #7d8da0; }
.ico.money { background: #fff1d6; color: #b07400; }
.ico.blue { background: #e3eefa; color: var(--ds-blue); }

.pill { display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .75rem; border-radius: 999px; font-size: .78rem; font-weight: 700; white-space: nowrap; }
.pill-yes { background: #dff5ea; color: #137a50; }
.pill-no { background: #fde4e8; color: #b0263c; }
.pill-wait { background: #eef1f5; color: #627387; }
.pill-sent { background: #e3eefa; color: #1d65a0; }
.pill-draft { background: #fff3d6; color: #8a6200; }
.pill-bad { background: #fde4e8; color: #b0263c; }

.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: .3rem; }
.dot.yes { background: #1f9d6b; } .dot.no { background: #d6334a; } .dot.wait { background: #aab8c6; }

.ds-empty { text-align: center; padding: 3.5rem 1.5rem; }
.ds-empty .big { font-size: 3.6rem; color: var(--ds-blue); }

/* A coloured dot that gently pulses: green = up, red = down, grey = unknown */
.status-dot { position: relative; flex: none; width: 13px; height: 13px; border-radius: 50%; background: #aab8c6; color: #aab8c6; }
.status-dot.up { background: #1f9d6b; color: #1f9d6b; }
.status-dot.down { background: #d6334a; color: #d6334a; }
.status-dot.up::after, .status-dot.down::after {
    content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 2px solid currentColor;
    animation: ds-pulse 2s ease-out infinite;
}
@keyframes ds-pulse { 0% { transform: scale(.55); opacity: .75; } 100% { transform: scale(1.5); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .status-dot::after { animation: none !important; } }

/* ==========================================================================
   Monitor: dashboard cards
   ========================================================================== */
.mon-card { margin-bottom: 1.25rem; }
.mon-head { display: flex; align-items: center; flex-wrap: wrap; gap: .9rem 1rem; padding: 1.05rem 1.3rem; border-bottom: 1px solid var(--ds-line); }
.mon-title { font-size: 1.15rem; font-weight: 700; color: var(--ds-navy); overflow-wrap: anywhere; line-height: 1.2; }
.mon-sub { font-size: .84rem; color: var(--ds-muted); }
.mon-head .grow { flex: 1 1 200px; min-width: 0; }
.mon-actions { display: flex; flex-wrap: wrap; gap: .4rem; }
.mon-actions form { margin: 0; }
.mon-body { display: grid; grid-template-columns: 230px 1fr; gap: 1.2rem 1.6rem; padding: 1.2rem 1.3rem 1.3rem; }
@media (max-width: 767.98px) { .mon-body { grid-template-columns: 1fr; } }
.uptime-big { font-size: 2.5rem; font-weight: 700; line-height: 1; letter-spacing: -.02em; }
.uptime-big small { font-size: 1rem; font-weight: 700; margin-left: .1rem; }
.uptime-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .07em; color: var(--ds-muted); font-weight: 700; margin-top: .3rem; }
.tone-good { color: #1f9d6b; } .tone-warn { color: #b87d00; } .tone-bad { color: #d6334a; } .tone-none { color: #8a99aa; }
.stat-tile .n.tone-good { color: #1f9d6b; } .stat-tile .n.tone-warn { color: #b87d00; } .stat-tile .n.tone-bad { color: #d6334a; } .stat-tile .n.tone-none { color: #8a99aa; }
.mon-facts { list-style: none; padding: 0; margin: 1rem 0 0; font-size: .87rem; color: var(--ds-muted); }
.mon-facts li { display: flex; gap: .55rem; align-items: baseline; margin-bottom: .4rem; }
.mon-facts i { color: var(--ds-blue); width: 1.1rem; text-align: center; }
.mon-facts .warn, .mon-facts .warn i { color: #b87d00; }
.chart-box { position: relative; height: 175px; }
.chart-box.tall { height: 260px; }

/* ==========================================================================
   Invoice: list, filter chips, form summary, logo box
   ========================================================================== */
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip {
    border: 1px solid var(--ds-line); background: #fff; color: var(--ds-navy);
    border-radius: 999px; padding: .38rem .95rem; font-family: inherit; font-weight: 700; font-size: .82rem;
    cursor: pointer; transition: background-color .15s ease, color .15s ease, transform .15s ease;
}
.chip:hover { transform: translateY(-2px); }
.chip.active { background: var(--ds-navy); border-color: var(--ds-navy); color: #fff; }
.chip .n { opacity: .65; margin-left: .3rem; font-weight: 700; }
.money { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.ref { font-weight: 700; color: var(--ds-navy); }
.sub-line { font-size: .8rem; color: var(--ds-muted); overflow-wrap: anywhere; }
.row-actions { display: flex; gap: .4rem; justify-content: flex-end; flex-wrap: wrap; }
.row-actions form { margin: 0; }

.item-card { background: #f6f9fc; border: 1px solid var(--ds-line); border-radius: 14px; padding: .9rem 1rem .6rem; margin-bottom: .8rem; }
.item-card .item-no { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--ds-muted); margin-bottom: .5rem; }
@media (min-width: 992px) { .summary-sticky { position: sticky; top: 1rem; } }
.sum-row { display: flex; justify-content: space-between; gap: 1rem; padding: .3rem 0; color: var(--ds-muted); }
.sum-row b { color: var(--ds-ink); font-variant-numeric: tabular-nums; }
.sum-items { list-style: none; margin: .4rem 0 .6rem; padding: 0; }
.sum-items li { display: flex; justify-content: space-between; gap: 1rem; padding: .35rem 0; border-bottom: 1px dashed var(--ds-line); font-size: .92rem; }
.sum-items li span:first-child { overflow-wrap: anywhere; }
.sum-total { display: flex; justify-content: space-between; margin-top: .6rem; padding-top: .8rem; border-top: 2px solid var(--ds-line); font-size: 1.4rem; font-weight: 700; color: var(--ds-navy); font-variant-numeric: tabular-nums; }
.send-note { display: flex; gap: .6rem; align-items: flex-start; padding: .75rem .9rem; border-radius: 12px; font-size: .85rem; margin-top: 1rem; }
.send-note i { font-size: 1.1rem; line-height: 1.3; }
.send-note.auto { background: #e6f8ef; color: #0e6b45; }
.send-note.manual { background: #fff3d6; color: #7a5600; }

.logo-box { width: 100%; aspect-ratio: 16 / 9; display: grid; place-items: center; border: 2px dashed #c8d5e2; border-radius: 14px; background: #f6f9fc; overflow: hidden; color: var(--ds-muted); text-align: center; }
.logo-box img { max-width: 88%; max-height: 88%; object-fit: contain; }
.logo-box i { font-size: 2.4rem; display: block; margin-bottom: .3rem; }
