/* MediaHost Upload Portal - Global Styles */

:root {
    --primary-color: #0084ff;
    --primary-dark: #0044ff;
    --secondary-color: #343a40;
    --success-color: #3c763d;
    --error-color: #a94442;
    --warning-color: #8a6d3b;
    --info-color: #31708f;
    --background-gray: #acacac;
    --border-radius: 0.3rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: var(--background-gray);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Top Navigation Bar */
.top-navbar {
    background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
    text-decoration: none;
}

.navbar-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.navbar-menu a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: background-color 0.3s;
}

.navbar-menu a:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.navbar-menu a.active {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1rem;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
    color: white;
}

.btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

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

.btn-secondary:hover {
    background-color: #23272b;
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-danger:hover {
    background-color: #c82333;
}

.btn-success {
    background-color: #28a745;
    color: white;
}

.btn-success:hover {
    background-color: #218838;
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-label.required::after {
    content: " *";
    color: #dc3545;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 132, 255, 0.1);
}

.form-control.error {
    border-color: var(--error-color);
}

.form-error {
    color: var(--error-color);
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

select.form-control {
    cursor: pointer;
}

/* Cards */
.card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    margin-bottom: 2rem;
}

.card-header {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f0f0f0;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

table thead {
    background-color: var(--secondary-color);
    color: white;
}

table th,
table td {
    padding: 1rem;
    text-align: left;
}

table tbody tr {
    border-bottom: 1px solid #f0f0f0;
}

table tbody tr:hover {
    background-color: #f8f9fa;
}

/* Progress Bar */
.progress-bar {
    display: none;
    height: 25px;
    background-color: #ccc;
    border-radius: var(--border-radius);
    overflow: hidden;
    margin: 1rem 0;
}

.progress-bar.active {
    display: block;
}

.progress-bar .progress {
    height: 100%;
    background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
    width: 0%;
    transition: width 0.3s ease-in-out;
}

/* Flash Messages / Alerts */
.flash-messages {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    max-width: 400px;
}

.flash-message,
.alert {
    padding: 1rem;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.flash-message.error,
.alert-danger {
    background-color: #f2dede;
    color: var(--error-color);
    border: 1px solid #ebccd1;
}

.flash-message.success,
.alert-success {
    background-color: #dff0d8;
    color: var(--success-color);
    border: 1px solid #d6e9c6;
}

.flash-message.warning,
.alert-warning {
    background-color: #fcf8e3;
    color: var(--warning-color);
    border: 1px solid #faebcc;
}

.flash-message.info,
.alert-info {
    background-color: #d9edf7;
    color: var(--info-color);
    border: 1px solid #bce8f1;
}

/* Page Layout */
.page-container {
    min-height: calc(100vh - 80px);
    padding: 2rem 0;
}

.page-title {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: #333;
}

/* Login Page Specific */
.gradient-custom-2 {
    background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
}

.gradient-form {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Pagination */
.pagination {
    display: flex;
    list-style: none;
    gap: 0.5rem;
    margin: 2rem 0;
    justify-content: center;
}

.pagination li {
    display: inline-block;
}

.pagination a,
.pagination span {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    text-decoration: none;
    color: #333;
    cursor: pointer;
}

.pagination a:hover {
    background-color: #f8f9fa;
}

.pagination .active span {
    background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
    color: white;
    border-color: var(--primary-color);
}

/* Responsive */
@media (max-width: 768px) {
    .navbar-container {
        flex-direction: column;
        gap: 1rem;
    }

    .navbar-menu {
        flex-direction: column;
        gap: 0.5rem;
        width: 100%;
    }

    .navbar-menu a {
        width: 100%;
        text-align: center;
    }

    .card {
        padding: 1rem;
    }

    table {
        font-size: 0.875rem;
    }

    table th,
    table td {
        padding: 0.5rem;
    }
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

.d-flex { display: flex; }
.justify-content-between { justify-content: space-between; }
.align-items-center { align-items: center; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
