/* Custom CSS for MTG Deck Builder Landing Page */

/* Root Variables - CardForge color scheme */
:root {
    --primary-color: #dfcc79; /* Golden accent */
    --secondary-color: #1c2120; /* Dark primary */
    --dark-bg: #1c2120; /* Same as secondary */
    --dark-card: #2a2f2d; /* Slightly lighter than dark-bg */
    --text-light: #fefefe; /* White */
    --text-muted-cardforge: #a0a0a0; /* Muted white */
    --accent-gold: #dfcc79; /* Golden accent */
    --success-green: #10b981;
    --danger-red: #ef4444;
    --warning-yellow: #f59e0b;
    
    /* Keep MTG mana colors for reference */
    --mana-white: #fffbd5;
    --mana-blue: #0e68ab;
    --mana-black: #150b00;
    --mana-red: #d3202a;
    --mana-green: #00733e;
    
    /* Bootstrap overrides */
    --bs-primary: #dfcc79;
    --bs-primary-rgb: 223, 204, 121;
}

/* Bootstrap Primary Color Overrides */
.text-primary {
    color: var(--accent-gold) !important;
}

.bg-primary-gold {
    background-color: var(--accent-gold) !important;
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--dark-bg);
    color: var(--text-light);
    line-height: 1.6;
}

/* Navbar Styles */
.navbar-brand {
    font-size: 1.5rem;
    color: var(--accent-gold) !important;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-logo {
    height: 32px;
    width: auto;
    max-width: 32px;
}

.navbar-dark .navbar-nav .nav-link {
    color: var(--text-light) !important;
    transition: color 0.3s ease;
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: var(--accent-gold) !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--secondary-color) 100%);
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" patternUnits="userSpaceOnUse" width="100" height="100"><circle cx="50" cy="50" r="1" fill="%23ffffff" opacity="0.05"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.text-gradient {
    background: linear-gradient(135deg, var(--text-light) 0%, var(--accent-gold) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-stats h4 {
    font-weight: bold;
    margin-bottom: 0;
}

/* Magic Card Stack Animation */
.hero-image {
    position: relative;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-stack {
    position: relative;
    width: 450px;  /* Increased to accommodate wider spread */
    height: 420px;
}

.magic-card {
    position: absolute;
    width: 200px;
    height: 280px;
    border-radius: 7px;
    background: linear-gradient(145deg, var(--dark-card), var(--secondary-color));
    border: 2px solid var(--primary-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.magic-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0px;
}

/* Loading state styling for magic cards */
.magic-card .loading-placeholder {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100%;
    color: var(--primary-color);
    text-align: center;
    padding: 1rem;
}

.magic-card .loading-placeholder i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    opacity: 0.7;
}

.magic-card .loading-placeholder span {
    font-size: 0.8rem;
    opacity: 0.8;
}

.card-1 {
    top: 0;
    left: 150px;  /* Moved further right */
    transform: rotate(-10deg);
    background: linear-gradient(145deg, var(--mana-blue), var(--secondary-color));
    animation: float 6s ease-in-out infinite;  /* Doubled animation time */
    z-index: 3;
}

.card-2 {
    top: 70px;  /* More vertical spacing */
    left: 75px;  /* More horizontal spacing */
    transform: rotate(5deg);
    background: linear-gradient(145deg, var(--mana-red), var(--secondary-color));
    animation: float 6s ease-in-out infinite 2s;  /* Doubled animation time */
    z-index: 2;
}

.card-3 {
    top: 140px;  /* Much more vertical spacing */
    left: 0;
    transform: rotate(-5deg);
    background: linear-gradient(145deg, var(--mana-green), var(--secondary-color));
    animation: float 6s ease-in-out infinite 4s;  /* Doubled animation time */
    z-index: 1;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(var(--rotation, 0deg)); }
    50% { transform: translateY(-15px) rotate(var(--rotation, 0deg)); }  /* Reduced floating distance */
}

.card-1 { --rotation: -10deg; }
.card-2 { --rotation: 5deg; }
.card-3 { --rotation: -5deg; }

/* Feature Cards */
.bg-dark-subtle {
    background-color: var(--secondary-color) !important;
}

.feature-card {
    background: var(--dark-card);
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(28, 33, 32, 0.2);
    height: 100%;
}

.feature-card:hover {
    transform: translateY(-10px);
    border-color:var(--accent-gold);
    box-shadow: 0 20px 40px rgba(28, 33, 32, 0.2);
}

.feature-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-gold));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: white;
}

.feature-card h4 {
    color: var(--text-light);
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-muted-cardforge);
    margin-bottom: 0;
}


.text-muted-cardforge {
    color: var(--text-muted-cardforge) !important;
}
/* Pricing Cards */
.pricing-card {
    background: var(--dark-card);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    position: relative;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    height: 100%;
}

.pricing-card.featured {
    border-color: var(--primary-color);
    transform: scale(1.05);
    background: linear-gradient(135deg, var(--dark-card), var(--secondary-color));
}

.pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.pricing-card.featured:hover {
    transform: scale(1.05) translateY(-10px);
}

.pricing-badge {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: white;
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: bold;
}

.pricing-header h4 {
    color: var(--text-light);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.price {
    margin-bottom: 2rem;
}

.price .currency {
    font-size: 1.2rem;
    color: var(--text-muted-cardforge);
}

.price .amount {
    font-size: 3rem;
    font-weight: bold;
    color: var(--primary-color);
}

.price .period {
    font-size: 1rem;
    color: var(--text-muted-cardforge);
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin-bottom: 2rem;
}

.pricing-features li {
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features li i {
    margin-right: 0.75rem;
    width: 20px;
}

.pricing-features li.disabled {
    color: var(--text-muted-cardforge);
    opacity: 0.6;
}

.pricing-features li .fa-check {
    color: var(--success-green);
}

.pricing-features li .fa-times {
    color: var(--danger-red);
}

/* Deck Showcase */
.deck-showcase {
    background: var(--dark-card);
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    height: 100%;
}

.deck-showcase:hover {
    transform: translateY(-5px);
    border-color: var(--accent-gold);
    box-shadow: 0 15px 30px rgba(28, 33, 32, 0.2);
}

.deck-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-gold));
    border-radius: 10px;
    margin-bottom: 1rem;
    position: relative;
    overflow: hidden;
}

.deck-image::before {
    content: '🃏';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    opacity: 0.7;
}

.deck-showcase h5 {
    color: var(--text-light);
    margin-bottom: 0.75rem;
}

.deck-showcase p {
    color: var(--text-muted-cardforge);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.deck-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Gallery Card Styles */
.gallery-card {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    background: var(--dark-card);
    border: 2px solid rgba(255, 255, 255, 0.1);
    height: 350px;
}

.gallery-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--accent-gold);
    box-shadow: 0 20px 40px rgba(223, 204, 121, 0.3);
}

.gallery-card .card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s ease;
}

.gallery-card:hover .card-image {
    transform: scale(1.05);
}

.gallery-card .card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(28, 33, 32, 0.95));
    color: var(--text-light);
    padding: 1.5rem 1rem 1rem;
    transform: translateY(100%);
    transition: all 0.3s ease;
}

.gallery-card:hover .card-overlay {
    transform: translateY(0);
}

.gallery-card .card-overlay h6 {
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.gallery-card .card-overlay p {
    color: var(--text-muted-cardforge);
    margin-bottom: 0;
    font-size: 0.85rem;
}

/* Carousel Customization */
.carousel-control-prev,
.carousel-control-next {
    width: 5%;
    color: var(--primary-color);
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: var(--primary-color);
    border-radius: 50%;
    padding: 20px;
}

.carousel-indicators button {
    background-color: var(--primary-color);
}

/* Button Styles */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-gold));
    border: none;
    border-radius: 10px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(223, 204, 121, 0.4);
    background: linear-gradient(135deg, var(--accent-gold), var(--primary-color));
    color: white !important;
}

/* Navigation button specific styles */
.navbar .nav-link.btn-primary:hover {
    color: white !important;
    box-shadow: 0 10px 25px rgba(223, 204, 121, 0.4);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 10px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(28, 33, 32, 0.2);
}

.btn-outline-light {
    border: 2px solid var(--text-light);
    color: var(--text-light);
    border-radius: 10px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline-light:hover {
    background: var(--text-light);
    color: var(--dark-bg);
    transform: translateY(-2px);
}

/* Footer */
footer {
    background: var(--secondary-color) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

footer a {
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--accent-gold) !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        text-align: center;
        padding-top: 100px;
    }
    
    .hero-image {
        margin-top: 2rem;
        margin-bottom: 2rem;
        height: 300px;
    }
    
    .card-stack {
        width: 250px;
        height: 350px;
    }
    
    .magic-card {
        width: 150px;
        height: 210px;
    }
    
    .pricing-card.featured {
        transform: none;
        margin-top: 1rem;
    }
    
    .hero-stats {
        justify-content: center;
        flex-wrap: wrap;
        gap: 1rem !important;
        padding-bottom: 2rem;
    }
    
    .display-4 {
        font-size: 2.5rem;
    }
    
    .display-5 {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .pricing-card,
    .feature-card,
    .deck-showcase {
        margin-bottom: 1rem;
    }
    
    .btn-lg {
        font-size: 1rem;
        padding: 0.5rem 1.5rem;
    }
}

/* Loading Animation */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus States for Accessibility */
.btn:focus,
.nav-link:focus {
    outline: 2px solid var(--accent-gold);
    outline-offset: 2px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--secondary-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-gold);
}

/* Coming Soon Section */
.coming-soon-card {
    padding: 2rem;
    border-radius: 15px;
    background: rgba(42, 47, 45, 0.8);
    border: 1px solid rgba(223, 204, 121, 0.2);
}

/* Newsletter Section */
#newsletter {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--secondary-color) 100%);
}

.newsletter-card {
    background: linear-gradient(135deg, var(--dark-card) 0%, rgba(42, 47, 45, 0.9) 100%);
    border-radius: 20px;
    padding: 3rem 2.5rem;
    border: 1px solid rgba(223, 204, 121, 0.2);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}


.min-vh-65 {
    min-height: 80vh;
}
.newsletter-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-gold));
}

.newsletter-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-gold));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    font-size: 2rem;
    color: var(--secondary-color);
    box-shadow: 0 10px 30px rgba(223, 204, 121, 0.3);
}

.newsletter-form .form-control {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(223, 204, 121, 0.2);
    border-radius: 10px;
    color: var(--text-light);
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.newsletter-form .form-control:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(223, 204, 121, 0.1);
    color: var(--text-light);
}

.newsletter-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-form .form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.newsletter-benefits i {
    font-size: 1.5rem;
    display: block;
    margin-bottom: 0.5rem;
}

.newsletter-form .btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-gold));
    border: none;
    color: var(--secondary-color);
    font-weight: 600;
    border-radius: 50px;
    padding: 0.875rem 2.5rem;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(223, 204, 121, 0.3);
}

.newsletter-form .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(223, 204, 121, 0.4);
    background: linear-gradient(135deg, var(--accent-gold), var(--primary-color));
}

.newsletter-form .btn-primary:active {
    transform: translateY(0);
}

.newsletter-form .btn-primary:disabled {
    opacity: 0.7;
    transform: none;
    cursor: not-allowed;
}

/* Loading state */
.newsletter-form .btn-primary.loading {
    position: relative;
    color: transparent;
}

.newsletter-form .btn-primary.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    border: 2px solid var(--secondary-color);
    border-top: 2px solid transparent;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* Newsletter alert styles */
#newsletterMessage.alert-success {
    background: linear-gradient(135deg, var(--success-green), #059669);
    border: 1px solid #10b981;
    color: white;
    border-radius: 10px;
}

#newsletterMessage.alert-danger {
    background: linear-gradient(135deg, var(--danger-red), #dc2626);
    border: 1px solid #ef4444;
    color: white;
    border-radius: 10px;
}

/* Mobile responsiveness for newsletter */
@media (max-width: 768px) {
    .newsletter-card {
        padding: 2rem 1.5rem;
        margin: 0 1rem;
    }
    
    .newsletter-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .newsletter-form .btn-primary {
        width: 100%;
        padding: 1rem;
    }
    
    .newsletter-benefits .col-md-3 {
        margin-bottom: 1rem;
    }
}