:root {
    --tc-bg: #0b1016;
    --tc-surface: #111923;
    --tc-surface-raised: #17222e;
    --tc-border: rgba(190, 219, 224, 0.12);
    --tc-text: #f2f7f5;
    --tc-muted: #9aabae;
    --tc-accent: #65e6ad;
    --tc-accent-deep: #2fc58e;
    --tc-radius: 18px;
    --accent-color: #42d99b;
    --accent-muted: rgba(66, 217, 155, 0.46);
    --accent-neutral: rgba(66, 217, 155, 0.24);
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 88px;
}

body,
main.bg-elegant-dark,
#sections.bg-elegant-dark {
    background: var(--tc-bg) !important;
    color: var(--tc-text);
    font-family: "Roboto", "Segoe UI", sans-serif;
}

body {
    background-image:
        radial-gradient(ellipse at 50% 0, rgba(44, 113, 94, 0.16), transparent 48%),
        linear-gradient(180deg, #0d141b 0%, var(--tc-bg) 65%);
    line-height: 1.65;
}

::selection {
    color: #07110d;
    background: var(--tc-accent);
}

::-webkit-scrollbar {
    width: 9px;
}

::-webkit-scrollbar-track {
    background: #0b1016;
}

::-webkit-scrollbar-thumb {
    border: 2px solid #0b1016;
    border-radius: 99px;
    background: #34474b;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--tc-accent-deep);
}

a {
    color: var(--tc-accent);
    transition: color 180ms ease, opacity 180ms ease;
}

a:hover {
    color: #a1ffd0;
}

.navbar.navbar-main {
    position: sticky;
    top: 0;
    z-index: 1000 !important;
    min-height: 76px;
    border-bottom: 1px solid rgba(190, 219, 224, 0.08);
    background: rgba(10, 16, 22, 0.84) !important;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.16);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.navbar-brand img {
    max-height: 48px;
    width: auto;
}

.navbar .nav-link {
    padding: 0.7rem 1rem !important;
    color: rgba(242, 247, 245, 0.78) !important;
    font-weight: 600;
    transition: color 180ms ease, background 180ms ease;
}

.navbar .nav-link:hover,
.navbar .nav-link:focus {
    border-radius: 10px;
    color: var(--tc-accent) !important;
    background: rgba(101, 230, 173, 0.08);
}

#welcome-section {
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(430px, 56vw, 650px);
    padding: 100px 0 125px;
    isolation: isolate;
    background-color: #101b20 !important;
}

#welcome-section::before {
    position: absolute;
    z-index: -1;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(8, 15, 20, 0.9) 0%, rgba(8, 15, 20, 0.65) 48%, rgba(8, 15, 20, 0.22) 100%),
        linear-gradient(0deg, var(--tc-bg) 0%, transparent 34%);
    content: "";
}

#welcome-section .container {
    width: 100%;
}

#welcome-section .shop-title {
    position: relative;
}

#welcome-section .shop-title::before {
    display: inline-flex;
    align-items: center;
    margin-bottom: 22px;
    padding: 7px 13px;
    border: 1px solid rgba(101, 230, 173, 0.34);
    border-radius: 99px;
    color: #b7f5d5;
    background: rgba(17, 35, 31, 0.68);
    content: "MINECRAFT • TESTYCRAFT";
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
}

#welcome-section .shop-name {
    max-width: 720px;
    color: #fff;
    font-size: clamp(3.3rem, 8vw, 6.5rem);
    letter-spacing: -0.055em;
    line-height: 0.98 !important;
    text-shadow: 0 8px 40px rgba(0, 0, 0, 0.38);
}

#welcome-section .fh-300 {
    max-width: min(100%, 390px);
    max-height: 390px;
    object-fit: contain;
    filter: drop-shadow(0 24px 55px rgba(58, 224, 157, 0.18));
    animation: tc-float 6s ease-in-out infinite;
}

#welcome-section .pattern.bottom {
    opacity: 0.14;
}

@keyframes tc-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

main > section.section-md {
    padding-top: clamp(56px, 8vw, 100px) !important;
    padding-bottom: clamp(64px, 8vw, 108px) !important;
}

main > section.section-md > .container {
    max-width: 1160px;
}

main > section.section-md h2 {
    color: var(--tc-text);
    letter-spacing: -0.035em;
}

main > section.section-md .d-flex.justify-content-between {
    gap: 24px;
    align-items: center;
    margin-bottom: 32px;
}

.form-control,
.input-group-text {
    min-height: 48px;
    border: 1px solid var(--tc-border) !important;
    border-radius: 12px !important;
    color: var(--tc-text) !important;
    background-color: var(--tc-surface) !important;
    box-shadow: none !important;
}

.form-control {
    padding: 0.7rem 1rem;
}

.form-control::placeholder {
    color: #819194 !important;
    opacity: 1;
}

.form-control:focus {
    border-color: rgba(101, 230, 173, 0.68) !important;
    box-shadow: 0 0 0 3px rgba(101, 230, 173, 0.12) !important;
}

.input-group .form-control,
.input-group .input-group-text {
    border-radius: 12px !important;
}

.input-group .input-group-append .input-group-text {
    margin-left: 7px;
}

.shop .card,
.shop [class*="product"] .card {
    overflow: hidden;
    border: 1px solid var(--tc-border) !important;
    border-radius: var(--tc-radius) !important;
    color: var(--tc-text);
    background: linear-gradient(145deg, rgba(25, 38, 49, 0.98), rgba(15, 24, 32, 0.98)) !important;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.18) !important;
    transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.shop .card:hover,
.shop [class*="product"] .card:hover {
    transform: translateY(-5px);
    border-color: rgba(101, 230, 173, 0.4) !important;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.32), 0 0 28px rgba(47, 197, 142, 0.08) !important;
}

.shop .card img {
    border-radius: 12px;
}

.btn,
button.btn {
    border-radius: 12px;
    font-weight: 700;
    transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.btn-primary,
.btn-primary:not(:disabled):not(.disabled) {
    border: 1px solid var(--tc-accent) !important;
    color: #08140e !important;
    background: linear-gradient(135deg, #82f2bd, #42d99b) !important;
    box-shadow: 0 8px 22px rgba(66, 217, 155, 0.2);
}

.btn-primary:hover,
.btn-primary:focus {
    transform: translateY(-2px);
    color: #06110b !important;
    background: linear-gradient(135deg, #a2ffd1, #65e6ad) !important;
    box-shadow: 0 12px 28px rgba(66, 217, 155, 0.3);
}

.btn-primary:focus-visible,
a:focus-visible,
button:focus-visible {
    outline: 3px solid rgba(101, 230, 173, 0.72);
    outline-offset: 3px;
}

.footer {
    border-top: 1px solid var(--tc-border);
    color: var(--tc-muted) !important;
    background: #080d12 !important;
}

.footer-brand img {
    max-height: 44px;
    width: auto;
}

#footer-social-links .btn {
    color: var(--tc-muted) !important;
}

#footer-social-links .btn:hover {
    color: var(--tc-accent) !important;
}

.modal-backdrop.show {
    opacity: 0.78;
    backdrop-filter: blur(5px);
}

.modal-content,
.cart-content {
    overflow: hidden;
    border: 1px solid var(--tc-border) !important;
    border-radius: 20px !important;
    color: var(--tc-text);
    background-color: var(--tc-surface) !important;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.48);
}

.cart-content .bg-elegant-dark {
    background-color: #0e151c !important;
}

.cart-content .text-white,
.cart-content h2,
.cart-content h3,
.cart-content p {
    color: var(--tc-text);
}

.cart-content .input-group-text,
.cart-content .form-control {
    color: var(--tc-text) !important;
    background-color: var(--tc-surface-raised) !important;
}

.cart-content .alert-warning {
    border: 1px solid rgba(255, 202, 102, 0.24);
    border-radius: 12px;
    color: #f8d99e;
    background: rgba(120, 82, 24, 0.2);
}

.cart-content .form-check-label,
.cart-content .small {
    color: var(--tc-muted);
}

.cart-content .text-primary,
.footer a[style] {
    color: var(--tc-accent) !important;
}

.cart-content #payment-type .modal-content,
#payment-type .modal-body {
    color: #182027;
    background: #f5f8f7 !important;
}

#payment-type .card {
    border-radius: 14px !important;
    transition: transform 180ms ease, box-shadow 180ms ease;
}

#payment-type .card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(18, 35, 30, 0.14) !important;
}

.stripe-loading-indicator .stripe,
.stripe-loading-indicator .stripe-loaded {
    background: var(--tc-accent) !important;
}

@media (max-width: 767.98px) {
    .navbar.navbar-main {
        min-height: 66px;
    }

    #welcome-section {
        min-height: 390px;
        padding: 78px 0 96px;
        text-align: center;
    }

    #welcome-section::before {
        background:
            linear-gradient(180deg, rgba(8, 15, 20, 0.55), rgba(8, 15, 20, 0.8)),
            linear-gradient(0deg, var(--tc-bg) 0%, transparent 40%);
    }

    #welcome-section .shop-name {
        font-size: clamp(3rem, 13vw, 5rem);
    }

    main > section.section-md .d-flex.justify-content-between {
        align-items: stretch !important;
        flex-direction: column;
    }

    main > section.section-md .form-group {
        width: 100%;
    }

    .modal-dialog {
        margin: 0.65rem;
    }

    .modal-content,
    .cart-content {
        border-radius: 16px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
