/* Medicine Module Styles */

/* Skeleton Loading Styles */
.skeleton-item {
    pointer-events: none;
}

.skeleton-img,
.skeleton-line {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: 4px;
}

.skeleton-img {
    width: 100%;
    height: 200px;
    border-radius: 0.375rem 0.375rem 0 0;
}

.skeleton-line {
    height: 16px;
    margin-bottom: 12px;
}

.skeleton-title {
    width: 80%;
    height: 20px;
}

.skeleton-subtitle {
    width: 60%;
    height: 14px;
}

.skeleton-text {
    width: 40%;
    height: 14px;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* View Mode Toggle - Professional Fixed Position */
.view-mode-toggle-wrapper {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    animation: slideInUp 0.3s ease-out;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translate(-50%, 20px);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

.view-mode-toggle-card {
    background: white;
    border-radius: 50px;
    padding: 12px 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1), 0 2px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
}

.view-mode-toggle-card:hover {
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.15), 0 3px 8px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.view-mode-toggle-card>div {
    width: 100%;
}

.mode-icon {
    color: #c0c0c0;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}

.mode-icon.active {
    color: #377dff;
    transform: scale(1.1);
}

.mode-icon-patient.active {
    color: #00c9a7;
}

.mode-icon-physician.active {
    color: #0056b3;
}

.mode-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #1e2022;
    white-space: nowrap;
    transition: color 0.3s ease;
}

#viewModeSwitch {
    width: 40px;
    height: 20px;
    cursor: pointer;
    margin: 0;
}

#viewModeSwitch:checked {
    background-color: #0056b3;
    border-color: #0056b3;
}

#viewModeSwitch:not(:checked) {
    background-color: #00c9a7;
    border-color: #00c9a7;
}

.form-check.form-switch {
    display: inline-flex;
    align-items: center;
    padding-left: 0;
    min-height: auto;
    margin-bottom: 0 !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .view-mode-toggle-card {
        padding: 8px 16px;
    }

    .mode-label {
        font-size: 0.8rem;
    }
}

@media (max-width: 576px) {
    .mode-label {
        display: none;
    }

    .view-mode-toggle-card {
        padding: 8px 12px;
    }
}

/* Smooth transition for content changes */
.content-wrapper {
    transition: opacity 0.2s ease-in-out;
}

.content-patient,
.content-physician {
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Custom badge colors for prescription types */
.badge.bg-purple {
    background-color: #6f42c1 !important;
}
