/* Sirilite Custom Mystical Styles */

:root {
    --mystical-purple: #6f42c1;
    --mystical-gold: #ffd700;
    --mystical-blue: #4c6ef5;
    --mystical-dark: #0d1117;
    --mystical-darker: #010409;
    --mystical-border: #21262d;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--mystical-dark);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, var(--mystical-purple), var(--mystical-blue));
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, var(--mystical-blue), var(--mystical-gold));
}

/* Body and base styles */
body {
    background: linear-gradient(135deg, #0d1117 0%, #1a1f2e 50%, #0d1117 100%);
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    position: relative;
    font-size: 1.05rem;
    line-height: 1.7;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(111, 66, 193, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(76, 110, 245, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(255, 215, 0, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Navigation styles */
.navbar {
    backdrop-filter: blur(10px);
    background: rgba(13, 17, 23, 0.95) !important;
    box-shadow: 0 2px 20px rgba(111, 66, 193, 0.2);
    z-index: 50;
}

.navbar-brand {
    font-size: 1.5rem;
    text-shadow: 0 0 10px rgba(111, 66, 193, 0.5);
}

.navbar-brand:hover {
    color: var(--mystical-gold) !important;
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.7);
}

.nav-link {
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--mystical-gold) !important;
    text-shadow: 0 0 8px rgba(255, 215, 0, 0.6);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--mystical-purple), var(--mystical-gold));
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 100%;
}

/* Dropdown menu */
.dropdown-menu {
    background: rgba(13, 17, 23, 0.95) !important;
    backdrop-filter: blur(10px);
    border: 1px solid var(--mystical-border);
    box-shadow: 0 10px 30px rgba(111, 66, 193, 0.3);
    z-index: 1060 !important;
    /* Higher than any content */
}

.dropdown-item {
    transition: all 0.3s ease;
}

.dropdown-item:hover {
    background: linear-gradient(45deg, rgba(111, 66, 193, 0.2), rgba(76, 110, 245, 0.2));
    color: var(--mystical-gold) !important;
}

/* Fix dropdown toggle positioning - let Bootstrap handle ::after */
.dropdown-toggle {
    cursor: pointer !important;
}

.dropdown-toggle:focus {
    box-shadow: none !important;
}

/* Buttons */
.btn-mystical {
    background: linear-gradient(45deg, var(--mystical-purple), var(--mystical-blue));
    border: none;
    color: white;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(111, 66, 193, 0.3);
}

.btn-mystical:hover {
    background: linear-gradient(45deg, var(--mystical-blue), var(--mystical-gold));
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(111, 66, 193, 0.4);
    color: white;
}

/* Gradient buttons */
.btn-gradient-primary {
    background: linear-gradient(135deg, #6f42c1 0%, #4c6ef5 100%);
    border: none;
    color: white;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(111, 66, 193, 0.3);
}

.btn-gradient-primary:hover {
    background: linear-gradient(135deg, #4c6ef5 0%, #6f42c1 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(111, 66, 193, 0.4);
    color: white;
}

.btn-gradient-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    border: none;
    color: white;
}

.btn-gradient-danger:hover {
    background: linear-gradient(135deg, #c82333 0%, #dc3545 100%);
    color: white;
}

.btn-gradient-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border: none;
    color: white;
}

.btn-gradient-success:hover {
    background: linear-gradient(135deg, #20c997 0%, #28a745 100%);
    color: white;
}

/* Cards */
.card-mystical {
    background: rgba(13, 17, 23, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid var(--mystical-border);
    box-shadow: 0 8px 32px rgba(111, 66, 193, 0.2);
    transition: all 0.3s ease;
}

.card-mystical:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(111, 66, 193, 0.3);
    border-color: var(--mystical-purple);
}

/* Glowing text effect */
.text-glow {
    text-shadow: 0 0 10px currentColor;
}

.text-glow-gold {
    color: var(--mystical-gold);
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.6);
}

.text-glow-purple {
    color: var(--mystical-purple);
    text-shadow: 0 0 15px rgba(111, 66, 193, 0.6);
}



/* Floating animation */
@keyframes float {

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

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

.floating {
    animation: float 3s ease-in-out infinite;
}

/* Sparkle animation */
@keyframes sparkle {

    0%,
    100% {
        opacity: 0;
        transform: scale(0);
    }

    50% {
        opacity: 1;
        transform: scale(1);
    }
}

.sparkle {
    animation: sparkle 2s ease-in-out infinite;
}

/* Loading spinner */
.loading-spinner {
    border: 4px solid rgba(111, 66, 193, 0.3);
    border-left: 4px solid var(--mystical-purple);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

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

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

/* Form styles */
.form-control:focus {
    border-color: var(--mystical-purple);
    box-shadow: 0 0 0 0.2rem rgba(111, 66, 193, 0.25);
}

.form-control {
    background: rgba(13, 17, 23, 0.8);
    border-color: var(--mystical-border);
    color: white;
}

.form-control::placeholder {
    color: #6c757d;
}

/* Invalid field highlighting */
.form-control.is-invalid,
.form-select.is-invalid {
    border-color: #dc3545 !important;
    box-shadow: 0 0 10px rgba(220, 53, 69, 0.4) !important;
    background-color: rgba(220, 53, 69, 0.05) !important;
}

.is-invalid+.invalid-feedback {
    display: block;
    font-weight: 500;
    margin-top: 0.5rem;
    animation: fadeIn 0.3s ease-in;
}

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

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

/* Footer */
footer {
    backdrop-filter: blur(10px);
    background: rgba(13, 17, 23, 0.95) !important;
}

/* Cookie consent */
.cookie-consent-banner {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    left: 1rem;
    z-index: 1080;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    max-width: 980px;
    margin: 0 auto;
    padding: 1rem;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 8px;
    background: rgba(13, 17, 23, 0.96);
    box-shadow: 0 18px 42px rgba(2, 6, 23, 0.48);
    backdrop-filter: blur(14px);
}

.cookie-consent-copy {
    max-width: 680px;
}

.cookie-consent-copy h2 {
    margin: 0 0 0.35rem;
    color: var(--mystical-gold);
    font-size: 1.05rem;
}

.cookie-consent-copy p {
    margin: 0;
    color: rgba(248, 250, 252, 0.84);
    font-size: 0.92rem;
    line-height: 1.55;
}

.cookie-consent-copy a {
    display: inline-flex;
    margin-top: 0.35rem;
    color: #8bd3ff;
    font-size: 0.9rem;
    text-decoration: none;
}

.cookie-consent-copy a:hover {
    color: var(--mystical-gold);
}

.cookie-consent-actions {
    display: flex;
    flex-shrink: 0;
    flex-wrap: wrap;
    gap: 0.6rem;
    justify-content: flex-end;
}

.cookie-settings-button {
    position: fixed;
    left: 1rem;
    bottom: 1rem;
    z-index: 1070;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 0.75rem;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 8px;
    background: rgba(13, 17, 23, 0.86);
    color: rgba(248, 250, 252, 0.86);
    font-size: 0.86rem;
    box-shadow: 0 10px 26px rgba(2, 6, 23, 0.32);
}

.cookie-settings-button:hover {
    color: var(--mystical-gold);
    border-color: rgba(255, 215, 0, 0.34);
}

/* Homepage hero */
.home-hero {
    min-height: 68vh;
    display: flex;
    align-items: center;
    padding: clamp(4rem, 8vw, 7rem) 0;
    background:
        linear-gradient(90deg, rgba(1, 4, 9, 0.9) 0%, rgba(13, 17, 23, 0.72) 46%, rgba(13, 17, 23, 0.24) 100%),
        url("/images/hero-mystical.png") center right / cover no-repeat;
    border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.home-hero .lead {
    max-width: 44rem;
    color: rgba(248, 250, 252, 0.9) !important;
}

.home-feature-symbol {
    width: 240px;
    height: 240px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 215, 0, 0.28);
    border-radius: 8px;
    background: rgba(13, 17, 23, 0.45);
}

.home-feature-symbol .bi {
    font-size: 5rem;
    color: var(--mystical-gold);
}

/* Editorial visuals */
.visual-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(1.4rem, 3vw, 2.6rem);
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(13, 17, 23, 0.94), rgba(30, 24, 48, 0.78)),
        rgba(13, 17, 23, 0.82);
    box-shadow: 0 18px 46px rgba(2, 6, 23, 0.26);
}

.visual-hero::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 215, 0, 0.42), transparent);
}

.visual-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin-bottom: 0.85rem;
    color: var(--mystical-gold);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.visual-hero .lead {
    color: rgba(248, 250, 252, 0.86) !important;
}

.visual-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.visual-hero-picture,
.editorial-picture {
    display: block;
    width: 100%;
}

.visual-hero-image,
.editorial-image {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
    object-fit: cover;
    box-shadow: 0 16px 38px rgba(2, 6, 23, 0.35);
}

.visual-hero-image {
    aspect-ratio: 16 / 9;
}

.visual-card-image {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid rgba(148, 163, 184, 0.18);
}

.visual-side-note {
    padding: 1rem;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 8px;
    background: rgba(2, 6, 23, 0.28);
}

@media (max-width: 991.98px) {
    .visual-hero {
        padding: 1.25rem;
    }
}

/* Responsive design */
@media (max-width: 768px) {
    .cookie-consent-banner {
        display: block;
        right: 0.75rem;
        bottom: 0.75rem;
        left: 0.75rem;
    }

    .cookie-consent-actions {
        justify-content: stretch;
        margin-top: 0.85rem;
    }

    .cookie-consent-actions .btn {
        flex: 1 1 100%;
    }

    .cookie-settings-button {
        left: 0.75rem;
        bottom: 0.75rem;
    }


    .navbar-brand {
        font-size: 1.2rem;
    }
}

/* Icon animations */
.bi {
    transition: all 0.3s ease;
}

.nav-link:hover .bi,
.dropdown-item:hover .bi {
    transform: scale(1.1);
    color: var(--mystical-gold);
}

/* Custom text styles */
.text-mystical {
    background: linear-gradient(45deg, var(--mystical-purple), var(--mystical-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Shadow effects */
.shadow-mystical {
    box-shadow: 0 10px 30px rgba(111, 66, 193, 0.3) !important;
}

.shadow-mystical-lg {
    box-shadow: 0 15px 40px rgba(111, 66, 193, 0.4) !important;
}

/* Article content styling */
.article-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #e0e0e0;
}

.article-content p {
    margin-bottom: 1.5rem;
}

.article-content strong,
.article-content b {
    color: #ffd700;
    font-weight: 600;
}

.article-content em,
.article-content i {
    color: #b19cd9;
    font-style: italic;
}

.article-content h2,
.article-content h3,
.article-content h4 {
    color: #ffd700;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.article-content ul,
.article-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.article-content li {
    margin-bottom: 0.5rem;
}

.article-content blockquote {
    border-left: 4px solid #6f42c1;
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #b19cd9;
}

/* Global text improvements for better readability across the entire site */
.text-secondary {
    color: #c0c5ce !important;
}

.text-muted {
    color: #c0c5ce !important;
}

.lead {
    font-size: 1.3rem !important;
    color: #9ca3af !important;
    line-height: 1.6;
}

.small,
small {
    font-size: 0.925rem;
}

.card-text {
    line-height: 1.6;
}

p {
    margin-bottom: 1rem;
}

/* Ensure breadcrumb is readable */
.breadcrumb-item,
.breadcrumb-item a {
    color: #9ca3af !important;
}

.breadcrumb-item.active {
    color: #d1d5db !important;
}

/* Flatpickr datepicker styling for dark theme */
.flatpickr-calendar {
    background: rgba(13, 17, 23, 0.95) !important;
    border: 1px solid var(--mystical-border) !important;
    box-shadow: 0 10px 30px rgba(111, 66, 193, 0.3) !important;
    color: #e0e0e0 !important;
}

.flatpickr-months {
    background: linear-gradient(135deg, #6f42c1 0%, #4c6ef5 100%) !important;
    color: white !important;
}

.flatpickr-month {
    color: white !important;
}

.flatpickr-current-month {
    color: white !important;
}

.flatpickr-weekdays {
    background: rgba(111, 66, 193, 0.2) !important;
}

.flatpickr-weekday {
    color: #d1d5db !important;
}

.flatpickr-day {
    color: #e0e0e0 !important;
}

.flatpickr-day:hover {
    background: rgba(111, 66, 193, 0.3) !important;
    border-color: var(--mystical-purple) !important;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
    background: linear-gradient(135deg, #6f42c1 0%, #4c6ef5 100%) !important;
    border-color: var(--mystical-purple) !important;
    color: white !important;
}

.flatpickr-day.today {
    border-color: var(--mystical-gold) !important;
}

.flatpickr-day.today:hover {
    background: rgba(255, 215, 0, 0.2) !important;
}

.flatpickr-input {
    background: rgba(13, 17, 23, 0.8) !important;
    border-color: var(--mystical-border) !important;
    color: white !important;
}

.flatpickr-input:focus {
    border-color: var(--mystical-purple) !important;
    box-shadow: 0 0 0 0.2rem rgba(111, 66, 193, 0.25) !important;
}

/* ==============================================
   FIX #11: Reduce excessive whitespace between sections
   ============================================== */
section.py-5 {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
}

.min-vh-75 {
    min-height: 60vh !important;
}

/* ==============================================
   FIX #20: Floating CTA Button
   ============================================== */
.floating-cta {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 22px;
    background: linear-gradient(135deg, var(--mystical-purple) 0%, #f59e0b 100%);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    box-shadow: 0 6px 25px rgba(111, 66, 193, 0.5), 0 0 40px rgba(245, 158, 11, 0.2);
    font-weight: 600;
    font-size: 0.95rem;
    opacity: 0;
    transform: translateY(20px) scale(0.9);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
}

.floating-cta.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.floating-cta:hover {
    color: white;
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 35px rgba(111, 66, 193, 0.6), 0 0 60px rgba(245, 158, 11, 0.3);
}

.floating-cta .bi {
    font-size: 1.1rem;
    animation: pulse-star 2s ease-in-out infinite;
}

@keyframes pulse-star {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }
}

@media (max-width: 576px) {
    .floating-cta {
        bottom: 20px;
        right: 20px;
        padding: 12px 18px;
        font-size: 0.85rem;
    }

    .floating-cta-text {
        display: none;
    }

    .floating-cta {
        border-radius: 50%;
        padding: 16px;
    }
}

/* SEO detail pages */
.detail-page .card {
    border-radius: 8px;
    border-color: rgba(148, 163, 184, 0.16);
    background: rgba(13, 17, 23, 0.72);
}

.detail-page .card-header {
    background: rgba(17, 24, 39, 0.72);
    border-bottom-color: rgba(148, 163, 184, 0.16);
}

.detail-side-card {
    position: sticky;
    top: 5rem;
}

.detail-tip {
    min-height: 100%;
    padding: 1rem;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 8px;
    background: rgba(2, 6, 23, 0.34);
}

.detail-tip .bi {
    font-size: 1.45rem;
}

.stone-detail-image,
.stone-detail-placeholder {
    width: 220px;
    height: 220px;
    max-width: 100%;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 12px 28px rgba(2, 6, 23, 0.36);
}

.stone-detail-placeholder,
.card-detail-placeholder,
.related-stone-placeholder,
.related-card-placeholder {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(111, 66, 193, 0.75), rgba(76, 110, 245, 0.75));
    color: white;
}

.card-detail-image,
.card-detail-placeholder {
    width: 220px;
    height: 340px;
    max-width: 100%;
    border-radius: 8px;
    object-fit: cover;
    box-shadow: 0 12px 28px rgba(2, 6, 23, 0.36);
}

.related-stone-image,
.related-stone-placeholder {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
}

.related-card-image,
.related-card-placeholder {
    width: 80px;
    height: 120px;
    border-radius: 8px;
    object-fit: cover;
}

.meaning-content {
    font-size: 1.02rem;
    line-height: 1.75;
}

.text-glow,
.text-glow-gold,
.text-glow-purple {
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.18);
}

@media (max-width: 991.98px) {
    .detail-side-card {
        position: static;
    }
}
