:root {
    --primary: #52b5b2;
    --primary-dark: #347c7a;
    --secondary: #f8e9b6;
    --secondary-dark: #e7d69c;
    --light: #fffbe8;
    --dark: #3a3835;
}

.text-primary {
    color: var(--primary);
}

.text-secondary {
    color: var(--secondary-dark);
}

.text-light {
    color: var(--light);
}

.text-purple {
    color: var(--primary-dark);
}

.bg-primary {
    background-color: var(--primary);
}

.bg-light {
    background-color: var(--light);
}

.bg-pattern::before {
    content: '';
    position: fixed;
    inset: -20%;
    background-image: url('../img/logo-light.png');
    background-repeat: repeat;
    background-size: 150px;
    opacity: 0.05;
    pointer-events: none;
    z-index: 10;
    transform: rotate(-15deg) scale(1.2);
}

.btn-primary {
    background-color: var(--primary);
    padding: 5px 10px;
    color: var(--light);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 0;
    transition: color 0.3s ease;
}

.btn-primary::before {
    content: "";
    position: absolute;
    inset: 0;
    width: 0;
    background-color: var(--secondary);
    border-radius: 0.25rem;
    transition: width 0.3s ease;
    z-index: -1;
}

.btn-primary:hover::before {
    width: 100%;
}

.btn-primary:hover {
    color: var(--primary);
}

.btn-secondary {
    background-color: var(--secondary);
    padding: 5px 10px;
    color: var(--primary);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 0;
    transition: color 0.3s ease;
}

.btn-secondary::before {
    content: "";
    position: absolute;
    inset: 0;
    width: 0;
    background-color: var(--primary);
    border-radius: 0.25rem;
    transition: width 0.3s ease;
    z-index: -1;
}

.btn-secondary:hover::before {
    width: 100%;
}

.btn-secondary:hover {
    color: var(--secondary);
}

html {
    font-family: 'Montserrat';
    font-weight: 400;
    color: var(--dark);
    font-size: 17px;
    caret-color: var(--secondary);
}

body {
    min-height: 100vh;
    margin: 0;
    background: var(--light);
    display: flex;
}

.app-sidebar {
    width: 80px;
    height: 100vh;
    color: var(--primary);
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 1000;
}

.page-content {
    min-width: 0;
}

.page-content.has-sidebar {
    margin-left: 180px;
}

h1 {
    font-weight: 500;
}

.form-group label {
    color: var(--primary-dark);
    font-size: 0.8rem;
}

.form-group input {
    padding: 3px 7px;
    display: block;
    border-bottom: 1.5px solid var(--primary);
    border-radius: 3px;
    transition: all 0.2s ease;
}

.form-group input:focus {
    border-color: var(--primary-dark);
}

.form-group input:read-only {
    background-color: #e2e2e26d;
    cursor: not-allowed;
}

.nav-item-link {
    transition: background-color 0.25s ease, color 0.25s ease, transform 0.25s ease;
    position: relative;
    border-radius: 3px;
}

.nav-item-label {
    position: absolute;
    font-size: 1rem;
    margin-left: 40px;
    opacity: 0;
    color: var(--secondary-dark);
    transition: all 0.2s ease;
}

.nav-item:hover .nav-item-label {
    opacity: 1;
    transform: translateX(5px);
}

.nav-item-link.active {
    background-color: var(--secondary);
}

.manage-card {
    background-color: #fffff5;
    border-radius: 5px;
    padding: 1rem;
    transition: transform 0.2s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    border: solid 1px var(--secondary);
}

.manage-card-icon {
    min-width: 50px;
    color: var(--secondary);
}

.manage-card:hover {
    transform: translateY(-5px);
}

.manage-card-title {
    color: var(--primary);
    min-height: 25px;
    font-size: 1.2rem;
}

.manage-card-text {
    font-size: 0.9rem;
    width: 80%;
}

.info-hint-wrapper {
    position: relative;
    display: inline-flex;
}

.info-hint {
    position: absolute;
    left: 50%;
    top: calc(100% + 0.5rem);
    z-index: 40;
    display: none;
    width: min(18rem, calc(100vw - 3rem));
    transform: translateX(-50%);
    border: 1px solid var(--secondary);
    border-radius: 5px;
    background-color: #fffff5;
    box-shadow: 0 12px 28px rgba(58, 56, 53, 0.14);
    color: var(--dark);
    font-size: 0.75rem;
    line-height: 1.35;
    padding: 0.75rem;
}

.info-hint-wrapper:hover .info-hint,
.info-hint-wrapper.is-open .info-hint {
    display: block;
}

.badge {
    font-size: 9px;
    background-color: var(--primary);
    color: var(--light);
    padding: 2px 8px;    
    border-radius: 3px;
}

.badge-scheduled {
    background-color: var(--secondary);
    color: var(--primary);
}

[data-swipe-card] {
    touch-action: pan-y;
}

.breadcrumb {
    font-size: 0.7rem;
    color: var(--secondary-dark);
}

.checkbox {
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    user-select: none;
}

.checkbox input {
    display: none;
}

.checkmark {
    width: 17px;
    height: 17px;
    border: 1.5px solid var(--primary);
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
    appearance: none;
    position: relative;
}

.checkbox input:checked + .checkmark {
    background: var(--primary);
}

.checkbox input:checked + .checkmark::after {
    content: '\f00c';
    font-family: 'Font Awesome 7 Free';
    font-weight: 900;
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
}

.tab-menu {    
    --tab-index: 0;
    display: flex;
    position: absolute;
    top: 2rem;
    gap: 7px;
    padding: 0;
    background-color: var(--secondary);
    border-radius: 4px;
    overflow: hidden;
}

.tab-menu::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    height: 100%;
    background-color: var(--primary);
    border-radius: 4px;
    transform: translateX(calc(var(--tab-index) * 100%));
    transition: transform 0.28s ease;
}

.tab-item {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1 1 0;
    white-space: nowrap;
    position: relative;
    z-index: 1;
    padding: 5px 10px;
    border-radius: 4px;
    color: var(--primary);
    transition: color 0.28s ease, font-weight 0.28s ease;
}

.tab-item.active {
    color: var(--light);
    font-weight: 600;
}

.auth-column {
    position: relative;
}

.auth-logo {
    display: block;
    margin: 0 auto;
}

.tab-stage {
    position: relative;
    overflow: visible;
    padding: 1px;
    transition: height 0.28s ease;
}

.tab {
    inset: 0 auto auto 0;
    opacity: 0;
    pointer-events: none;
    position: absolute;
    transform: translateX(1.5rem);
    transition: opacity 0.28s ease, transform 0.28s ease;
    width: 100%;
}

.tab.is-active {
    opacity: 1;
    pointer-events: auto;
    position: relative;
    transform: translateX(0);
}

.tab.is-before {
    transform: translateX(-1.5rem);
}

.tab.is-after {
    transform: translateX(1.5rem);
}

.input-error-text {
    font-size: 0.8rem;
    color: var(--primary-dark);
    opacity: 0.5;
}

.form-group:has(input[data-type*="required"]) label::after {
    content: ' *';
    color: var(--secondary-dark);
    font-size: 1rem;
}

@media (max-width: 600px) {
    .page-content.has-sidebar {
        margin-left: 0;
        padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px));
    }

    body {
        flex-direction: column;
    }

    .app-sidebar {
       top: auto;
       right: 20px;
       bottom: 10px;
       left: 10px;
       position: fixed;
    }

    .app-sidebar .nav-item {
        flex: 1 1 0;
        justify-content: center;
    }

    .app-sidebar .nav-item-new {
        position: absolute;
        top: -3.75rem;
        right: 0;
        flex: 0 0 auto;
    }

    .app-sidebar .nav-item-new .nav-item-link {
        width: 3rem;
        height: 3rem;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background-color: var(--secondary);
        color: var(--primary);
        border-radius: 0.375rem;
        box-shadow: 0 0.25rem 0.7rem rgba(176, 105, 217, 0.24);
    }

    .app-sidebar .nav-item-new .nav-item-label {
        display: none;
    }

    .app-sidebar .nav-item:has(.nav-item-link.active) {
        background-color: var(--secondary);
        border-radius: 999px;
        padding: 0.375rem 0.75rem;
        gap: 0.375rem;
        flex: 0 1 auto;
    }

    .app-sidebar .nav-item-link.active {
        background-color: transparent;
        color: var(--primary);
    }

    .app-sidebar .nav-item-link.active ~ .nav-item-label {
        position: static;
        display: inline-block;
        opacity: 1;
        margin: 0;
        transform: none;
        color: var(--primary);
        font-size: 0.9rem;
        font-weight: 600;
        white-space: nowrap;
    }

    .nav-item-label {
        color: var(--primary);
    }

    .tab-menu {
        top: 1rem;
    }
}
