/* Custom styles for RhinoAssam - Vibrant V2 */

/* -------------------------------------------------------------------------- */
/*                                1. Variables                                */
/* -------------------------------------------------------------------------- */
:root {
    /* Brand Colors - Deep Teal & Vibrant Mint */
    --primary-gradient-start: #0f3d3e;
    /* Deep Teal */
    --primary-gradient-end: #105c5d;
    /* Lighter Teal */
    --accent-color: #00d2d3;
    /* Cyan/Mint */
    --accent-hover: #00a8a9;

    /* Text Colors */
    --text-main: #2d3436;
    --text-muted: #636e72;
    --text-light: #ffffff;

    /* Backgrounds */
    --body-bg: #f5f7fa;
    --card-bg: #ffffff;

    /* Fonts */
    --heading-font: 'Poppins', sans-serif;
    --body-font: 'Inter', sans-serif;

    /* UI Elements */
    --border-radius: 16px;
    --btn-radius: 50px;
    /* Pill shape */
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);

    /* Shadows */
    --shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.08);
    /* Modern diffuse shadow */
    --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.12);
}

/* -------------------------------------------------------------------------- */
/*                              2. Global Styles                              */
/* -------------------------------------------------------------------------- */
body {
    font-family: var(--body-font);
    background-color: var(--body-bg);
    color: var(--text-main);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6,
.navbar-brand {
    font-family: var(--heading-font);
    font-weight: 700;
    color: var(--primary-gradient-start);
}

a {
    text-decoration: none;
    transition: var(--transition);
}

/* -------------------------------------------------------------------------- */
/*                                3. Navigation                               */
/* -------------------------------------------------------------------------- */
.navbar {
    background: rgba(255, 255, 255, 0.95) !important;
    padding: 1rem 0;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-size: 1.6rem;
    background: linear-gradient(135deg, var(--primary-gradient-start), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.nav-link {
    color: var(--text-main) !important;
    font-weight: 600;
    margin-left: 15px;
    position: relative;
}

.nav-link:hover {
    color: var(--accent-color) !important;
}

.navbar-toggler {
    border: none;
    padding: 0.6rem 0.8rem;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(15, 61, 62, 0.08), rgba(0, 210, 211, 0.08));
    position: relative;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.navbar-toggler:hover {
    background: linear-gradient(135deg, rgba(15, 61, 62, 0.12), rgba(0, 210, 211, 0.12));
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 210, 211, 0.2);
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 3px rgba(0, 210, 211, 0.2);
    outline: none;
}

.navbar-toggler:active {
    transform: scale(0.98);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(15, 61, 62, 0.9)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2.5' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    width: 24px;
    height: 24px;
    transition: var(--transition);
}

/* -------------------------------------------------------------------------- */
/*                               4. Hero Section                              */
/* -------------------------------------------------------------------------- */
.hero-section {
    background: linear-gradient(135deg, var(--primary-gradient-start) 0%, var(--primary-gradient-end) 100%);
    padding: 100px 0 140px;
    /* Extra bottom padding for overlap/shape */
    position: relative;
    color: var(--text-light);
    clip-path: polygon(0 0, 100% 0, 100% 90%, 0 100%);
    /* Angled bottom */
    margin-bottom: 2rem;
}

.hero-section h1 {
    color: var(--text-light);
    font-weight: 800;
    letter-spacing: -1px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hero-section .lead {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
    font-size: 1.2rem;
}

.hero-logo {
    max-height: 220px;
    filter: drop-shadow(0 15px 30px rgba(0, 0, 0, 0.2));
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-15px);
    }

    100% {
        transform: translateY(0px);
    }
}

/* -------------------------------------------------------------------------- */
/*                                5. Components                               */
/* -------------------------------------------------------------------------- */

/* Section Headings */
.section-title {
    position: relative;
    display: inline-block;
    margin-bottom: 3rem;
    color: var(--primary-gradient-start);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--accent-color);
    border-radius: 2px;
}

/* Cards */
.card {
    border: none;
    border-radius: var(--border-radius);
    background: var(--card-bg);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
    overflow: visible;
    /* Needed if we used negative margins, but using transform here */
}

.card-content-wrapper {
    border-radius: var(--border-radius);
    overflow: hidden;
    /* Keep content inside radius */
    height: 100%;
    background: #fff;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.app-thumbnail {
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card:hover .app-thumbnail {
    transform: scale(1.05);
}

.card-body {
    padding: 1.5rem;
    position: relative;
    z-index: 2;
    background: #fff;
}

.card-title {
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.card-text {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Badges */
.badge {
    padding: 0.5em 1em;
    font-weight: 600;
    border-radius: 8px;
    font-size: 0.7rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Buttons */
.btn {
    border-radius: var(--btn-radius);
    padding: 0.75rem 2rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-size: 0.85rem;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background: linear-gradient(45deg, var(--primary-gradient-start), var(--primary-gradient-end));
    color: #fff;
    box-shadow: 0 4px 15px rgba(15, 61, 62, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(15, 61, 62, 0.4);
    background: linear-gradient(45deg, var(--primary-gradient-start), var(--primary-gradient-end));
    /* Keep gradient */
}

.btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.8);
    background: transparent;
    color: #fff;
}

.btn-outline-light:hover {
    background: #fff;
    color: var(--primary-gradient-start);
    border-color: #fff;
}

.btn-success {
    background: var(--accent-color);
    color: #fff;
    /* or dark depending on contrast */
    box-shadow: 0 4px 15px rgba(0, 210, 211, 0.3);
}

/* -------------------------------------------------------------------------- */
/*                                   6. CTA                                   */
/* -------------------------------------------------------------------------- */
.cta-section {
    background: #fff;
    border-radius: 20px;
    padding: 4rem 2rem;
    box-shadow: var(--shadow-md);
    margin-top: 2rem;
    /* Adjusted for negative margin overlap if used */
    position: relative;
    overflow: hidden;
    z-index: 10;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-gradient-start), var(--accent-color));
}

.cta-section .btn {
    background: var(--text-main);
    /* Dark dark button */
    color: #fff;
}

.cta-section .btn:hover {
    background: #000;
}

/* -------------------------------------------------------------------------- */
/*                                  7. Footer                                 */
/* -------------------------------------------------------------------------- */
footer {
    background-color: var(--text-main);
    color: rgba(255, 255, 255, 0.6);
    padding: 3rem 0;
    font-size: 0.9rem;
}

footer a {
    color: rgba(255, 255, 255, 0.8);
}

footer a:hover {
    color: var(--accent-color);
}

/* -------------------------------------------------------------------------- */
/*                              8. Responsive                                 */
/* -------------------------------------------------------------------------- */
@media (max-width: 768px) {
    .hero-section {
        padding: 60px 0 100px;
        text-align: center;
        clip-path: polygon(0 0, 100% 0, 100% 95%, 0 100%);
    }

    .hero-logo {
        max-height: 160px;
        margin-bottom: 20px;
    }

    .section-title {
        font-size: 1.75rem;
    }
}

/* Dashboard Stat Cards */
.stat-card {
    border: none;
    border-radius: var(--border-radius);
    color: #fff;
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.stat-card.bg-primary {
    background: linear-gradient(135deg, var(--primary-gradient-start), var(--primary-gradient-end)) !important;
}

.stat-card .card-title {
    color: #fff !important;
    font-weight: 700;
}

.stat-card .card-text {
    color: rgba(255, 255, 255, 0.8) !important;
}

.stat-card .card-header {
    background: rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.stat-card .card-body {
    background: transparent !important;
}

/* Loading Spinner (Preserved) */
.card .loading-spinner {
    /* ... existing styles adaptable ... */
    height: 220px;
    /* Match new thumbnail height */
    z-index: 20;
    border-radius: var(--border-radius);
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    width: 100%;
}

.card .loading-spinner::after {
    content: "";
    width: 30px;
    height: 30px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.card-content-wrapper {
    visibility: hidden;
    opacity: 0;
}

.card-content-wrapper.loaded {
    visibility: visible;
    opacity: 1;
    animation: fadeIn 0.6s ease forwards;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}