﻿/* wwwroot/Content/CSS/layout.css */

/* ===== RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Roboto', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    color: #333333;
    background-color: #f8f9fa;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', 'Arial Black', Gadget, sans-serif;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: #2c3e50;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.75rem;
}

h4 {
    font-size: 1.5rem;
}

h5 {
    font-size: 1.25rem;
}

h6 {
    font-size: 1rem;
}

p {
    margin-bottom: 1rem;
}

a {
    color: #3498db;
    text-decoration: none;
    transition: color 0.3s ease;
}

    a:hover {
        color: #2980b9;
        text-decoration: underline;
    }

/* ===== LAYOUT CONTAINERS ===== */
.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.container-fluid {
    width: 100%;
    padding: 0 20px;
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.col {
    flex: 1;
    padding: 0 15px;
    min-width: 300px;
}

/* ===== MAIN CONTENT AREA ===== */
.main-content {
    min-height: calc(100vh - 300px); /* Adjust based on header/footer height */
    padding-top: 160px; /* Space for fixed header */
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

.content-wrapper {
    padding: 40px 0;
}

.page-title {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    padding-bottom: 20px;
}

    .page-title::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 100px;
        height: 4px;
        background: linear-gradient(90deg, #3498db, #2c3e50);
        border-radius: 2px;
    }

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    padding: 12px 30px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

    .btn::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
        transition: left 0.5s ease;
        z-index: -1;
    }

    .btn:hover::before {
        left: 100%;
    }

.btn-primary {
    background: linear-gradient(135deg, #3498db 0%, #2c3e50 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

    .btn-primary:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
        color: white;
        text-decoration: none;
    }

.btn-secondary {
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(149, 165, 166, 0.3);
}

    .btn-secondary:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(149, 165, 166, 0.4);
        color: white;
        text-decoration: none;
    }

.btn-accent {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);
}

    .btn-accent:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(231, 76, 60, 0.4);
        color: white;
        text-decoration: none;
    }

.btn-outline {
    background: transparent;
    color: #3498db;
    border: 2px solid #3498db;
}

    .btn-outline:hover {
        background: #3498db;
        color: white;
    }

.btn-lg {
    padding: 15px 40px;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 8px 20px;
    font-size: 0.9rem;
}

.btn-block {
    display: block;
    width: 100%;
}

/* ===== FORMS ===== */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #2c3e50;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    font-family: 'Roboto', sans-serif;
    font-size: 1rem;
    line-height: 1.5;
    color: #495057;
    background-color: #fff;
    background-clip: padding-box;
    border: 2px solid #ced4da;
    border-radius: 8px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

    .form-control:focus {
        border-color: #3498db;
        box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
        outline: 0;
    }

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

/* ===== CARDS ===== */
.card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 30px;
}

    .card:hover {
        transform: translateY(-10px);
        box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    }

.card-header {
    padding: 20px;
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
}

.card-body {
    padding: 25px;
}

.card-footer {
    padding: 20px;
    background-color: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

/* ===== UTILITY CLASSES ===== */
.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.text-primary {
    color: #3498db;
}

.text-secondary {
    color: #7f8c8d;
}

.text-success {
    color: #27ae60;
}

.text-danger {
    color: #e74c3c;
}

.text-warning {
    color: #f39c12;
}

.text-info {
    color: #3498db;
}

.text-light {
    color: #ecf0f1;
}

.text-dark {
    color: #2c3e50;
}

.bg-primary {
    background-color: #3498db;
}

.bg-secondary {
    background-color: #95a5a6;
}

.bg-success {
    background-color: #27ae60;
}

.bg-danger {
    background-color: #e74c3c;
}

.bg-warning {
    background-color: #f39c12;
}

.bg-light {
    background-color: #ecf0f1;
}

.bg-dark {
    background-color: #2c3e50;
}

.mt-1 {
    margin-top: 0.5rem;
}

.mt-2 {
    margin-top: 1rem;
}

.mt-3 {
    margin-top: 1.5rem;
}

.mt-4 {
    margin-top: 2rem;
}

.mt-5 {
    margin-top: 3rem;
}

.mb-1 {
    margin-bottom: 0.5rem;
}

.mb-2 {
    margin-bottom: 1rem;
}

.mb-3 {
    margin-bottom: 1.5rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

.mb-5 {
    margin-bottom: 3rem;
}

.ml-1 {
    margin-left: 0.5rem;
}

.ml-2 {
    margin-left: 1rem;
}

.ml-3 {
    margin-left: 1.5rem;
}

.ml-4 {
    margin-left: 2rem;
}

.ml-5 {
    margin-left: 3rem;
}

.mr-1 {
    margin-right: 0.5rem;
}

.mr-2 {
    margin-right: 1rem;
}

.mr-3 {
    margin-right: 1.5rem;
}

.mr-4 {
    margin-right: 2rem;
}

.mr-5 {
    margin-right: 3rem;
}

.p-1 {
    padding: 0.5rem;
}

.p-2 {
    padding: 1rem;
}

.p-3 {
    padding: 1.5rem;
}

.p-4 {
    padding: 2rem;
}

.p-5 {
    padding: 3rem;
}

.d-none {
    display: none;
}

.d-block {
    display: block;
}

.d-inline {
    display: inline;
}

.d-inline-block {
    display: inline-block;
}

.d-flex {
    display: flex;
}

.d-grid {
    display: grid;
}

.flex-row {
    flex-direction: row;
}

.flex-column {
    flex-direction: column;
}

.flex-wrap {
    flex-wrap: wrap;
}

.justify-start {
    justify-content: flex-start;
}

.justify-center {
    justify-content: center;
}

.justify-end {
    justify-content: flex-end;
}

.justify-between {
    justify-content: space-between;
}

.align-start {
    align-items: flex-start;
}

.align-center {
    align-items: center;
}

.align-end {
    align-items: flex-end;
}

.w-25 {
    width: 25%;
}

.w-50 {
    width: 50%;
}

.w-75 {
    width: 75%;
}

.w-100 {
    width: 100%;
}

.h-25 {
    height: 25%;
}

.h-50 {
    height: 50%;
}

.h-75 {
    height: 75%;
}

.h-100 {
    height: 100%;
}

.rounded {
    border-radius: 8px;
}

.rounded-circle {
    border-radius: 50%;
}

.rounded-pill {
    border-radius: 50rem;
}

.shadow-sm {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.shadow {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.shadow-lg {
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.position-relative {
    position: relative;
}

.position-absolute {
    position: absolute;
}

.position-fixed {
    position: fixed;
}

.position-sticky {
    position: sticky;
}

.overflow-hidden {
    overflow: hidden;
}

.overflow-auto {
    overflow: auto;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideDown {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from {
        transform: translateX(-20px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from {
        transform: translateX(20px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-10px);
    }

    60% {
        transform: translateY(-5px);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

.slide-up {
    animation: slideUp 0.5s ease forwards;
}

.slide-down {
    animation: slideDown 0.5s ease forwards;
}

.slide-left {
    animation: slideInLeft 0.5s ease forwards;
}

.slide-right {
    animation: slideInRight 0.5s ease forwards;
}

.pulse {
    animation: pulse 2s infinite;
}

.bounce {
    animation: bounce 2s infinite;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1200px) {
    .container {
        max-width: 1140px;
    }
}

@media (max-width: 992px) {
    .container {
        max-width: 960px;
    }

    h1 {
        font-size: 2.25rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    .main-content {
        padding-top: 140px;
    }
}

@media (max-width: 768px) {
    .container {
        max-width: 720px;
        padding: 0 15px;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    .main-content {
        padding-top: 120px;
    }

    .row {
        margin: 0 -10px;
    }

    .col {
        padding: 0 10px;
        min-width: 100%;
        margin-bottom: 20px;
    }
}

@media (max-width: 576px) {
    .container {
        max-width: 540px;
        padding: 0 10px;
    }

    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.25rem;
    }

    .main-content {
        padding-top: 100px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* ===== PRINT STYLES ===== */
@media print {
    body {
        background: white;
        color: black;
        font-size: 12pt;
    }

    .main-content {
        padding-top: 0;
    }

    .btn,
    .nav-menu,
    .mobile-toggle,
    .search-box {
        display: none !important;
    }

    a {
        color: black;
        text-decoration: underline;
    }

    .container {
        max-width: 100%;
        padding: 0;
    }
}

/* ===== ACCESSIBILITY ===== */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-to-content {
    position: absolute;
    top: -40px;
    left: 0;
    background: #2c3e50;
    color: white;
    padding: 8px 16px;
    z-index: 1001;
    text-decoration: none;
    border-radius: 0 0 4px 0;
    transition: top 0.3s ease;
}

    .skip-to-content:focus {
        top: 0;
    }

/* ===== DARK MODE SUPPORT ===== */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #1a1a1a;
        color: #e0e0e0;
    }

    .card {
        background-color: #2d2d2d;
        color: #e0e0e0;
    }

    .form-control {
        background-color: #3d3d3d;
        color: #e0e0e0;
        border-color: #4d4d4d;
    }

        .form-control:focus {
            border-color: #3498db;
            background-color: #3d3d3d;
        }
}

/* ===== SCROLLBAR STYLING ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #3498db 0%, #2c3e50 100%);
    border-radius: 5px;
}

    ::-webkit-scrollbar-thumb:hover {
        background: linear-gradient(135deg, #2980b9 0%, #1a252f 100%);
    }

/* ===== LOADING STATES ===== */
.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

    .loading::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 20px;
        height: 20px;
        margin: -10px 0 0 -10px;
        border: 2px solid #f3f3f3;
        border-top: 2px solid #3498db;
        border-radius: 50%;
        animation: spin 1s linear infinite;
    }

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}
