:root {
    --studio-brand: #206bc4;
}

.report-quick-periods,
.report-economics {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem 1.5rem;
}

.report-quick-periods .btn {
    flex: 1 1 10rem;
}

.report-signals {
    align-items: flex-start;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.report-signals .badge,
.collaborator-report .badge {
    font-size: inherit;
    letter-spacing: normal;
    line-height: 1.4;
    text-align: left;
    white-space: normal;
}

.report-hours {
    font-size: 1.125rem;
    font-variant-numeric: tabular-nums;
}

.report-current-work + .report-current-work {
    border-top: 1px solid var(--tblr-border-color);
    margin-top: .75rem;
    padding-top: .75rem;
}

.report-economics > div {
    flex: 1 1 12rem;
}

.report-activity-progress {
    max-width: 100%;
}

.collaborator-report,
#registrazioni {
    scroll-margin-top: 1rem;
}

@media print {
    .navbar,
    .skip-link,
    .footer,
    .collaborator-report .dt-search,
    .collaborator-report .dt-column-order,
    .collaborator-report .dt-length,
    .collaborator-report .dt-info,
    .collaborator-report .dt-paging {
        display: none !important;
    }

    .page-wrapper {
        margin: 0 !important;
    }

    .collaborator-report .table-responsive {
        overflow: visible;
    }

    .collaborator-report table {
        font-size: 10pt;
        table-layout: fixed;
    }

    .collaborator-report .table th,
    .collaborator-report .table td {
        min-width: 0 !important;
        overflow-wrap: anywhere;
        white-space: normal;
    }

    .collaborator-report .dtr-hidden {
        display: table-cell !important;
    }

    .collaborator-report tr.child,
    .collaborator-report .dtr-control::before {
        display: none !important;
    }

    .collaborator-report tr {
        break-inside: avoid;
    }

    .report-activity-progress {
        width: auto;
    }
}

.brand-mark {
    align-items: center;
    background: var(--studio-brand);
    border-radius: .5rem;
    color: #fff;
    display: inline-flex;
    font-size: .75rem;
    font-weight: 700;
    height: 2rem;
    justify-content: center;
    letter-spacing: .04em;
    width: 2rem;
}

.brand-mark-lg {
    border-radius: .75rem;
    font-size: 1.2rem;
    height: 3.5rem;
    width: 3.5rem;
}

.table td,
.table th {
    vertical-align: middle;
}

.form-help {
    margin-top: .35rem;
}

.detail-list dt,
.detail-list dd {
    margin-bottom: .75rem;
}

.btn-list form {
    display: inline-flex;
}

table.dataTable > tbody > tr.child ul.dtr-details {
    width: 100%;
}

table.dataTable > tbody > tr.child span.dtr-title {
    min-width: min(10rem, 100%);
}

/* One content rhythm across summaries, lists and forms. */
.page-body .container-fluid,
.page-header .container-fluid,
.footer .container-fluid {
    padding-inline: clamp(.875rem, 2vw, 2rem);
}

.page-wrapper,
.page-body .row > *,
.card,
.dt-container,
.form-control,
.form-select {
    min-width: 0;
}

.page-title,
.card-title,
.list-group-item,
.detail-list dd {
    overflow-wrap: anywhere;
}

.section-actions,
.section-actions .btn-list,
.section-actions .action-row {
    align-items: stretch;
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.section-actions {
    margin-bottom: 1rem;
}

.section-actions .btn-list {
    margin: 0;
    width: 100%;
}

.section-actions .action-row {
    width: 100%;
}

.section-actions > .btn,
.section-actions > form,
.section-actions .btn-list > *,
.section-actions .action-row > * {
    flex: var(--action-weight, 1) 1 calc((100% - 2.5rem) / 6);
    margin: 0 !important;
    min-width: min(100%, 9rem);
    order: 0;
}

.section-actions .action-row > * {
    flex-basis: 0;
    min-width: 0;
}

.section-actions .btn-primary {
    --action-weight: 2;
}

.section-actions [data-action-priority="3"] {
    --action-weight: 3;
}

.section-actions [data-action-priority="1"] {
    --action-weight: 1;
}

.section-actions .btn {
    height: 100%;
    min-height: 3rem;
    padding: .75rem;
    white-space: normal;
    width: 100%;
}

.section-actions form {
    display: flex;
}

.form-page {
    margin-inline: auto;
    max-width: 72rem;
    width: 100%;
}

.form-actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    justify-content: space-between;
}

.form-actions > .btn-primary {
    margin-left: auto;
}

.form-actions > .btn-outline-secondary {
    background-color: #f1f3f5;
}

.timer-decision-actions,
.confirmation-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.timer-decision-actions form {
    display: flex;
    min-width: 0;
}

.timer-decision-actions .btn,
.confirmation-actions .btn {
    height: 100%;
    min-height: 3rem;
    white-space: normal;
    width: 100%;
}

.section-filters > summary,
.section-help > summary,
details.card > summary {
    cursor: pointer;
    font-weight: 600;
    min-height: 2.75rem;
    padding: .875rem 1.25rem;
}

details.card > summary {
    display: flex;
    align-items: center;
    gap: .5rem;
    list-style: none;
}

details > summary::-webkit-details-marker {
    display: none;
}

details.card > summary::before,
.section-help > summary::before {
    content: "+";
    color: var(--studio-brand);
    flex: 0 0 1rem;
}

details[open] > summary::before {
    content: "−";
}

details:not([open]) > summary {
    border-bottom: 0;
}

details.card > summary .card-title {
    margin: 0;
}

.section-help > summary {
    padding-inline: 0;
}

.table-responsive,
table[data-datatable] {
    width: 100%;
}

table.dataTable.nowrap > tbody > tr > td,
table[data-datatable] > tbody > tr > td {
    overflow-wrap: anywhere;
    white-space: normal;
}

table.dataTable > tbody > tr:not(.child) > td {
    min-width: 6rem;
}

table.dataTable > tbody > tr:not(.child) > td:first-child {
    min-width: 9rem;
}

table.dataTable.document-table > tbody > tr:not(.child) > td:first-child {
    min-width: 14rem;
}

.dropdown-menu {
    max-width: calc(100vw - 1.75rem);
}

.dropdown-header {
    overflow-wrap: anywhere;
    white-space: normal;
}

table.dataTable > tbody > tr.child .dtr-data {
    overflow-wrap: anywhere;
    white-space: normal;
}

/* Bootstrap's DataTables adapter uses Bootstrap rows rather than dt-layout rows. */
@media (max-width: 767.98px) {
    .dt-container .dt-search,
    .dt-container .dt-length {
        display: flex;
        align-items: center;
        gap: .5rem;
        width: 100%;
    }

    .dt-container .dt-search input {
        flex: 1;
        margin-inline: 0;
        min-width: 0;
    }
}

.card-header,
.card-footer {
    flex-wrap: wrap;
    gap: .5rem;
}

.pagination {
    flex-wrap: wrap;
}

@media (max-width: 575.98px) {
    .form-actions > .btn {
        padding-inline: .75rem;
        white-space: normal;
    }

    .form-control,
    .form-select {
        font-size: 1rem;
        max-width: 100%;
    }

    table.dataTable > tbody > tr.child ul.dtr-details > li {
        display: flex;
        flex-direction: column;
        gap: .25rem;
    }

    .d-flex.justify-content-between {
        flex-wrap: wrap;
    }
}

.dt-container .dt-search input,
.dt-container .dt-length select {
    margin-left: .5rem;
}

.dt-container .row {
    margin-left: 0;
    margin-right: 0;
}

.dt-container .dt-layout-table > .col-12 {
    padding-inline: 0;
}

@media (max-width: 991.98px) {
    .page-header .row > .col-auto,
    .page-header .page-actions {
        margin-left: 0 !important;
        width: 100%;
    }

    .page-header .btn-list,
    .responsive-entity-row,
    .responsive-entity-row > .btn-list {
        width: 100%;
    }

    .page-header .btn-list,
    .responsive-entity-row > .btn-list {
        display: grid;
        grid-template-columns: 1fr;
    }

    .responsive-entity-row {
        align-items: stretch !important;
        flex-direction: column;
    }

    .detail-list dt,
    .detail-list dd {
        width: 100%;
    }

    .detail-list dt {
        margin-bottom: .2rem;
    }

    .dt-container .dt-layout-row {
        align-items: stretch;
        flex-direction: column;
        gap: .75rem;
    }

    .dt-container .dt-layout-cell,
    .dt-container .dt-search,
    .dt-container .dt-length,
    .dt-container .dt-search input,
    .dt-container .dt-length select {
        margin-left: 0 !important;
        width: 100%;
    }
}


.skip-link {
    background: #fff;
    border: 2px solid var(--studio-brand);
    border-radius: .375rem;
    color: #111827;
    left: 1rem;
    padding: .65rem 1rem;
    position: fixed;
    top: -5rem;
    z-index: 2000;
}

.skip-link:focus {
    top: 1rem;
}

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
    outline: 3px solid #ffbf47;
    outline-offset: 2px;
}

.btn,
.form-control,
.form-select,
.dropdown-item,
.nav-link {
    min-height: 2.75rem;
}

.table-responsive {
    -webkit-overflow-scrolling: touch;
    overflow-y: hidden;
}

.table th {
    white-space: nowrap;
}

/* Subtle stripes and cell borders keep summaries and long tables readable. */
.table {
    --tblr-table-striped-bg: rgba(var(--tblr-primary-rgb), .045);
    --tblr-table-border-color: var(--tblr-border-color);
}

.table > :not(caption) > * > * {
    border-bottom: 1px solid var(--tblr-table-border-color);
}

.table > :not(caption) > * > * + * {
    border-left: 1px solid var(--tblr-table-border-color);
}

.table > tbody > tr:nth-child(odd of :not(.child)) > * {
    --tblr-table-bg-type: var(--tblr-table-striped-bg);
}

.project-details-grid {
    display: grid;
    gap: 0 2rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.project-detail-column {
    margin: 0;
    min-width: 0;
}

.project-detail-column > div {
    align-items: baseline;
    border-bottom: 1px solid var(--tblr-border-color);
    display: grid;
    gap: .5rem 1rem;
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    padding: .75rem 0;
}

.project-detail-column > div:first-child {
    padding-top: 0;
}

.project-detail-column > div:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.project-detail-column dt {
    color: var(--tblr-secondary-color);
    font-weight: 400;
}

.project-detail-column dd {
    font-weight: 600;
    margin: 0;
    overflow-wrap: anywhere;
}

.project-details .badge,
.project-activity-meta .badge {
    font-size: inherit;
    letter-spacing: normal;
    white-space: normal;
}

.project-activity {
    padding: 1.5rem;
}

.project-activity-header,
.project-activity-controls,
.project-activity-meta {
    align-items: center;
    display: flex;
    gap: 1rem;
}

.project-activity-header {
    align-items: flex-start;
    justify-content: space-between;
}

.project-activity-heading {
    flex: 1;
    min-width: 0;
}

.project-activity-title {
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: .5rem;
}

.project-activity-meta {
    color: var(--tblr-secondary-color);
    flex-wrap: wrap;
    gap: .5rem 1rem;
}

.project-activity-controls {
    flex-shrink: 0;
}

.activity-progress {
    width: 12rem;
}

.activity-progress-label {
    align-items: baseline;
    display: flex;
    gap: .75rem;
    justify-content: space-between;
    margin-bottom: .25rem;
}

.activity-progress-label strong {
    color: var(--studio-brand);
    font-size: 1.25rem;
}

.activity-progress-bar {
    appearance: none;
    background: var(--tblr-border-color);
    border: 0;
    border-radius: 1rem;
    display: block;
    height: .625rem;
    overflow: hidden;
    width: 100%;
}

.activity-progress-bar::-webkit-progress-bar {
    background: var(--tblr-border-color);
}

.activity-progress-bar::-webkit-progress-value {
    background: var(--studio-brand);
    border-radius: 1rem;
}

.activity-progress-bar::-moz-progress-bar {
    background: var(--studio-brand);
    border-radius: 1rem;
}

.activity-hours-link {
    min-width: 6rem;
}

.project-activity-time {
    align-items: start;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.5rem;
    margin-top: 1.25rem;
}

.activity-time-total {
    align-items: center;
    background: rgba(var(--tblr-primary-rgb), .045);
    border: 1px solid var(--tblr-border-color);
    border-radius: var(--tblr-border-radius);
    display: flex;
    flex-wrap: wrap;
    gap: .5rem 1rem;
    padding: .875rem 1rem;
}

.activity-time-total strong {
    font-size: 1.25rem;
}

.project-activity .time-contributors {
    border: 1px solid var(--tblr-border-color);
    border-radius: var(--tblr-border-radius);
    max-width: 30rem;
    width: 100%;
}

.time-contributors .table {
    font-size: inherit;
}

.time-contributors .table > :not(caption) > * > * {
    padding: .625rem .875rem;
}

.time-contributors .table th {
    overflow-wrap: anywhere;
    white-space: normal;
}

.time-contributors .table tbody th {
    font-weight: 400;
}

.time-contributors .table tbody tr:last-child > * {
    border-bottom: 0;
}

@media (max-width: 991.98px) {
    .project-details-grid {
        grid-template-columns: minmax(0, 1fr);
        row-gap: 1.5rem;
    }

    .project-detail-column + .project-detail-column {
        border-top: 1px solid var(--tblr-border-color);
        padding-top: 1.5rem;
    }

    .project-activity-header {
        flex-direction: column;
        gap: 1.25rem;
    }

    .project-activity-controls {
        width: 100%;
    }

    .activity-progress {
        flex: 1;
        min-width: 0;
    }
}

@media (max-width: 575.98px) {
    .project-activity {
        padding: 1rem .875rem;
    }

    .project-detail-column > div {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
        column-gap: .75rem;
    }

    .activity-time-total {
        justify-content: space-between;
        width: 100%;
    }
}

@media (max-width: 575.98px) {
    .card-body,
    .card-header,
    .card-footer {
        padding-left: .875rem;
        padding-right: .875rem;
    }

    .table td,
    .table th {
        max-width: 18rem;
        overflow-wrap: anywhere;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
    }
}
