/* ------------------------- */
/* Project Cards Grid        */
/* ------------------------- */

.warning-action {
    color: #f5a623; /* Orange */
    transition: filter 0.3s ease;
    background-color: transparent;
    padding: 0;
    text-wrap: nowrap;
    text-decoration: underline;
    font-size: 14px;
}

.warning-action:hover {
    filter: brightness(85%);
}

.blocked-badge {
    display: inline-block;
    margin-left: 10px;
    vertical-align: middle;
    font-size: 12px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    background-color: var(--gloomy);
    color: var(--lead);
}

.projects-block {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    padding: 1rem;
}

@media (min-width: 1400px) {
    .projects-block {
        grid-template-columns: repeat(4, 1fr);
    }
}

.project-card {
    background-color: var(--white);
    color: var(--dark);
    aspect-ratio: 1 / 1;
    border-radius: 35px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.project-card.add {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--gloomy);
}

.card-inner {
    position: relative;
    margin: 6px;
    padding: 25px 25px 0 25px;
    height: 63%;
    border-radius: 33px;
    background-color: var(--light);
}

.card-btn {
    display: flex;
    padding: 10px 30px 0 30px;
    margin-bottom: 30px;
    justify-content: space-between;
}

/* ------------------------- */
/* Project Settings Page     */
/* ------------------------- */

img.project {
    width: 200px;
    height: 200px;
    border-radius: 100%;
    background-color: var(--style);
    align-content: center;
    text-align: center;
}

span.project-img {
    width: 200px;
    height: 200px;
    border-radius: 100%;
    background-color: var(--style);
    align-content: center;
    text-align: center;
    color: var(--dark);
    font-weight: 500;
    display: flex; 
    justify-content: center;
    align-items: center;
}

.project-name {
    padding-top: 30px;
    font-size: 30px;
    font-weight: 600;
    text-align: center;
}

.project-desc {
    margin-top: 20px;
    color: var(--style);
}

button.plus {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: var(--white);
    border-radius: 100%;
    border: var(--dark) 2px solid;
    color: var(--dark);
    font-size: 20px;
    font-weight: 600;
    transition: transform 0.3s ease;
}

button.plus:hover {
    transform: scale(1.1);
}

div.button {
    display: flex;
    align-items: center;
    gap: 10px;
    height: 50px;
    padding-left: 10px;
}

button.delete-project {
    color: var(--crimson);
    transition: filter 0.3s ease;
    background-color: transparent;
    padding: 0;
    text-wrap: nowrap;
    text-decoration: underline;
}

button.delete-project:hover {
    filter: brightness(85%);
}

/* Import Info Dropdown */
.import-header {
    display: flex;
    align-items: center;
    gap: 10px;
}


#tab3 {
    position: relative;
}

.info-icon-container {
    display: inline-block;
}

.info-icon {
    cursor: pointer;
    font-weight: bold;
    border: 1px solid var(--dark);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.info-dropdown {
    display: none;
    position: absolute;
    background-color: var(--white);
    border: 1px solid var(--gloomy);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    padding: 15px;
    width: 350px;
    z-index: 999;
    text-align: left;
    font-size: 0.8rem;
    
    /* New positioning */
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
}

#tab3 hr {
    border: 0;
    height: 2px;
    background-color: var(--gloomy, #eeeeee);
    margin: 20px 0;
}

.info-dropdown.show {
    display: block;
}

.info-dropdown h4 {
    margin-top: 0;
}

.info-dropdown ul {
    list-style-type: none;
    padding-left: 0;
    margin-bottom: 10px;
}

.info-dropdown li {
    margin-bottom: 5px;
}

.info-dropdown .btn {
    width: 100%;
    text-align: center;
}

/* Color coding for types and statuses */
.op-type-inflow { color: var(--green, #198754); font-weight: bold; }
.op-type-outflow { color: var(--crimson, #dc3545); font-weight: bold; }

.status-new { background-color: #cfe2ff; color: #0a58ca; padding: 2px 5px; border-radius: 4px; }
.status-applying { background-color: #ffecb3; color: #6d4c41; padding: 2px 5px; border-radius: 4px; }
.status-questions { background-color: #f8d7da; color: #842029; padding: 2px 5px; border-radius: 4px; }
.status-cancelled { background-color: #e9ecef; color: #495057; padding: 2px 5px; border-radius: 4px; }
.status-paid { background-color: #d1e7dd; color: #0f5132; padding: 2px 5px; border-radius: 4px; }
.status-closed { background-color: #e2e3e5; color: #41464b; padding: 2px 5px; border-radius: 4px; }

.export-btn {
    width: fit-content;
}

.import-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
}



@media (max-width: 768px) {
    .projects-block {
        gap: 1rem;
        padding: 0.5rem;
    }

    .project-card {
        border-radius: 25px;
    }

    .card-inner {
        padding: 15px;
        border-radius: 20px;
    }

    .card-btn {
        padding: 10px 20px 0 20px;
        margin-bottom: 20px;
    }

    .project-name {
        font-size: 24px;
    }

    #tab-switcher {
        background-color: var(--light);
        color: var(--dark);
        padding: 15px 20px;
        height: auto;
        background-position: right 20px center;
        font-weight: 500;
    }

    .tab-panel table, .tab-panel tbody {
        display: block;
        width: 100%;
    }

    .tab-panel thead {
        display: none;
    }

    .tab-panel tr {
        display: block;
        width: 100%;
        box-sizing: border-box;
        margin-bottom: 1rem;
        border: 1px solid var(--light);
        border-radius: 10px;
        padding: 1rem;
    }

    .tab-panel td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 0.5rem 0;
        border-bottom: 1px solid var(--light);
        text-align: right;
    }
    
    .tab-panel td:first-child {
        padding-left: 0;
    }
    
    .tab-panel td:last-child {
        border-bottom: none;
    }

    .tab-panel td::before {
        content: attr(data-label);
        font-weight: 600;
        color: var(--dark);
        text-align: left;
    }

    input, select, textarea {
        width: 220px;
    }


    .info-dropdown {
        width: 90%;
        right: 5%;
        top: auto;
        bottom: 100%;
        margin-bottom: 10px;
        transform: translateY(0);
    }
}
