/* ========================================
   Marcus Bradford - Red Noir Custom Styles
   Adapted from superdesign.dev Red Noir
   ======================================== */

/* === CSS Custom Properties === */
:root {
    --accent-red: #C41E3A;
    --accent-red-glow: rgba(196, 30, 58, 0.5);
    --bg-black: #0D0D0D;
    --bg-surface: #141414;
}

/* === Selection === */
.selection-red ::selection,
.selection-red::selection {
    background: #C41E3A;
    color: white;
}

/* === Font Classes === */
.font-manrope { font-family: 'Manrope', sans-serif; }
.font-inter { font-family: 'Inter', sans-serif; }

/* === Custom Properties for Animation === */
@property --gradient-angle {
    syntax: "<angle>";
    initial-value: 0deg;
    inherits: false;
}

/* === Keyframes === */
@keyframes fade-in-up {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes border-spin {
    from { --gradient-angle: 0deg; }
    to { --gradient-angle: 360deg; }
}

@keyframes animStar {
    from { transform: translateY(0px); }
    to { transform: translateY(-2000px); }
}

@keyframes ping {
    75%, 100% { transform: scale(2); opacity: 0; }
}

@keyframes pulse-green {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* === Animation Utilities === */
.animate-fade-up {
    opacity: 0;
    animation: fade-in-up 0.8s ease-out forwards;
}

.animate-fade-up.visible {
    opacity: 1;
    animation: fade-in-up 0.8s ease-out forwards;
}

/* === Global Background Effects === */
.site-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.site-bg .gradient-base {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, #1a0505, #0D0D0D);
}

.site-bg .stars-1 {
    position: absolute;
    top: 0;
    left: 0;
    width: 1px;
    height: 1px;
    background: transparent;
    box-shadow:
        234px 124px #fff, 654px 345px #fff, 876px 12px #fff,
        1200px 800px #fff, 400px 1500px #fff, 1800px 200px #fff,
        100px 1000px #fff, 900px 1900px #fff, 500px 600px #fff,
        1400px 100px #fff, 300px 400px #fff, 1600px 1200px #fff;
    animation: animStar 50s linear infinite;
}

.site-bg .stars-2 {
    position: absolute;
    top: 0;
    left: 0;
    width: 2px;
    height: 2px;
    background: transparent;
    box-shadow:
        123px 456px #fff, 789px 234px #fff, 456px 890px #fff,
        1100px 300px #fff, 200px 1200px #fff, 1500px 500px #fff,
        600px 1700px #fff, 1300px 900px #fff;
    animation: animStar 80s linear infinite;
}

.site-bg .ambient-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    height: 800px;
    background: rgba(196, 30, 58, 0.05);
    border-radius: 50%;
    filter: blur(120px);
}

.site-bg .grid-overlay {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    mask-image: radial-gradient(circle at center, black 40%, transparent 80%);
    -webkit-mask-image: radial-gradient(circle at center, black 40%, transparent 80%);
}

/* === Gradient Blur Header === */
.gradient-blur {
    position: fixed;
    z-index: 40;
    inset: 0 0 auto 0;
    height: 120px;
    pointer-events: none;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8), transparent);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    mask-image: linear-gradient(to bottom, black, transparent);
    -webkit-mask-image: linear-gradient(to bottom, black, transparent);
}

/* === Navbar === */
.site-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 50;
    padding-top: 1.5rem;
    padding-left: 1rem;
    padding-right: 1rem;
}

.site-nav-inner {
    max-width: 64rem;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 9999px;
    padding: 0.75rem 1.5rem;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
}

.site-nav-inner.scrolled {
    background: rgba(0,0,0,0.85);
    border-color: rgba(255,255,255,0.15);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: white;
}

.nav-logo-icon {
    width: 20px;
    height: 20px;
    background: #C41E3A;
    border-radius: 4px;
    transform: rotate(45deg);
}

.nav-logo-text {
    font-family: 'Manrope', sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.nav-links {
    display: none;
    align-items: center;
    gap: 2rem;
}

@media (min-width: 768px) {
    .nav-links { display: flex; }
}

.nav-links a {
    font-size: 0.875rem;
    font-weight: 500;
    color: #a1a1aa;
    text-decoration: none;
    transition: color 0.2s;
}

.nav-links a:hover { color: white; }

.nav-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-radius: 9999px;
    background: rgba(255,255,255,0.05);
    padding: 0.5rem 1.5rem;
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-decoration: none;
    transition: all 0.3s;
    cursor: pointer;
}

.nav-cta:hover {
    border-color: rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.1);
}

.nav-hamburger {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
}

@media (min-width: 768px) {
    .nav-hamburger { display: none; }
}

/* === Shiny CTA Button === */
.shiny-cta {
    --gradient-angle: 0deg;
    position: relative;
    overflow: hidden;
    border-radius: 9999px;
    padding: 1rem 2.5rem;
    background: linear-gradient(#0D0D0D, #0D0D0D) padding-box,
        conic-gradient(from var(--gradient-angle), transparent 0%, #C41E3A 5%, #C41E3A 15%, #C41E3A 30%, transparent 40%, transparent 100%) border-box;
    border: 2px solid transparent;
    cursor: pointer;
    isolation: isolate;
    animation: border-spin 2.5s linear infinite;
    color: white;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: transform 0.2s;
}

.shiny-cta:hover { transform: scale(1.02); }
.shiny-cta:active { transform: scale(0.98); }

.shiny-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, white 0.5px, transparent 0);
    background-size: 4px 4px;
    opacity: 0.1;
    z-index: 0;
}

.shiny-cta > * { position: relative; z-index: 1; }

/* === Ghost Button === */
.ghost-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-radius: 9999px;
    background: #18181b;
    border: 1px solid #27272a;
    color: #d4d4d8;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s;
}

.ghost-btn:hover {
    color: white;
    background: #27272a;
    border-color: #3f3f46;
}

/* === Red Label Pill === */
.label-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 1rem;
    border-radius: 9999px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.label-pill .dot-pulse {
    position: relative;
    display: flex;
    height: 8px;
    width: 8px;
}

.label-pill .dot-ping {
    position: absolute;
    display: inline-flex;
    height: 100%;
    width: 100%;
    border-radius: 9999px;
    background: #f87171;
    opacity: 0.75;
    animation: ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
}

.label-pill .dot-static {
    position: relative;
    display: inline-flex;
    border-radius: 9999px;
    height: 8px;
    width: 8px;
    background: #C41E3A;
}

.label-pill span {
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(254, 202, 202, 0.9);
    letter-spacing: 0.05em;
    font-family: 'Manrope', sans-serif;
}

/* === Section Labels === */
.section-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: #C41E3A;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-family: 'Inter', sans-serif;
}

/* === Card Styles === */
.feature-card {
    position: relative;
    overflow: hidden;
    padding: 2rem;
    border: 1px solid rgba(255,255,255,0.1);
    background: #0D0D0D;
    border-radius: 0.75rem;
    transition: all 0.3s;
}

.feature-card:hover {
    border-color: rgba(255,255,255,0.2);
}

.feature-card .card-glow {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    background: radial-gradient(circle at top right, #C41E3A, transparent 70%);
}

.feature-card:hover .card-glow { opacity: 0.1; }

.card-icon {
    display: inline-flex;
    padding: 0.75rem;
    border-radius: 0.5rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: #C41E3A;
    margin-bottom: 1rem;
}

.card-explore {
    display: flex;
    align-items: center;
    justify-content: space-between;
    opacity: 0;
    transform: translateY(0.5rem);
    transition: all 0.3s;
}

.feature-card:hover .card-explore {
    opacity: 1;
    transform: translateY(0);
}

/* === Split Sections === */
.split-section {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    align-items: center;
}

@media (min-width: 768px) {
    .split-section {
        grid-template-columns: 1fr 1fr;
    }
    .split-section.reversed { direction: rtl; }
    .split-section.reversed > * { direction: ltr; }
}

/* === Pull Quote === */
.pull-quote {
    border-left: 3px solid #C41E3A;
    padding-left: 1rem;
    font-weight: 600;
    font-family: 'Manrope', sans-serif;
    font-size: 1.125rem;
    color: #F5F5F5;
}

/* === Stats Counter === */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-family: 'Manrope', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: #C41E3A;
}

.stat-label {
    font-size: 0.875rem;
    color: #A0A0A0;
}

/* === Testimonials Banner === */
.testimonial-banner {
    width: 100%;
    background: #C41E3A;
    padding: 5rem 1.5rem;
}

.testimonial-banner .stars {
    display: flex;
    justify-content: center;
    gap: 0.25rem;
    color: black;
    margin-bottom: 1.5rem;
}

.testimonial-banner blockquote {
    font-family: 'Manrope', sans-serif;
    font-size: 1.875rem;
    font-weight: 700;
    color: black;
    text-align: center;
    max-width: 48rem;
    margin: 0 auto;
    line-height: 1.25;
}

@media (min-width: 768px) {
    .testimonial-banner blockquote { font-size: 3rem; }
}

/* === OPEN FOR WORK Badge === */
.open-for-work {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.5rem;
    background: #C41E3A;
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.875rem;
    border-radius: 9999px;
    font-family: 'Inter', sans-serif;
}

.open-for-work .green-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    animation: pulse-green 2s ease-in-out infinite;
}

/* === Text Stroke === */
.text-stroke {
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.1);
    color: transparent;
}

/* === Hero Gradient Text === */
.gradient-text {
    background: linear-gradient(to bottom, white, white, rgba(255,255,255,0.4));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* === Hero Underline SVG === */
.hero-red-underline {
    color: #C41E3A;
    display: inline-block;
    position: relative;
}

.hero-red-underline svg {
    position: absolute;
    width: 100%;
    height: 12px;
    bottom: -8px;
    left: 0;
    color: #C41E3A;
    opacity: 0.6;
}

/* === Smooth Scroll === */
html { scroll-behavior: smooth; }

/* === Portfolio Grid === */
.portfolio-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .portfolio-grid { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 1024px) {
    .portfolio-grid { grid-template-columns: 1fr 1fr 1fr 1fr; }
}

.portfolio-card {
    overflow: hidden;
    border-radius: 0.75rem;
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.3s;
}

.portfolio-card:hover {
    border-color: rgba(255,255,255,0.2);
    transform: translateY(-4px);
}

.portfolio-card img {
    width: 100%;
    aspect-ratio: 3/2;
    object-fit: cover;
}

/* === Contact Images === */
.contact-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.contact-images img {
    width: 100%;
    border-radius: 0.75rem;
    border: 1px solid rgba(255,255,255,0.1);
}

/* === Deftform Container === */
.deftform-container {
    border-radius: 0.75rem;
    border: 1px solid rgba(255,255,255,0.1);
    overflow: hidden;
    background: #141414;
    padding: 2rem;
}

.deftform-container iframe {
    width: 100%;
    min-height: 500px;
    border: none;
}

/* === Footer Huge Text === */
.footer-huge-text {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2.5rem 0;
    opacity: 0.2;
    pointer-events: none;
}

.footer-huge-text span {
    font-size: 15vw;
    line-height: 1;
    font-weight: 700;
    font-family: 'Manrope', sans-serif;
    letter-spacing: -0.05em;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.1);
    color: transparent;
    user-select: none;
}

/* === Services Grid === */
.services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 768px) {
    .services-grid { grid-template-columns: 1fr 1fr 1fr; }
}

/* === Hero Images Row === */
.hero-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-top: 3rem;
    max-width: 56rem;
    margin-left: auto;
    margin-right: auto;
}

.hero-images img {
    width: 100%;
    border-radius: 0.75rem;
    border: 1px solid rgba(255,255,255,0.1);
}

/* === Image with border accent === */
.img-border-accent {
    border-radius: 0.75rem;
    border: 2px solid #C41E3A;
}

/* === Responsive Container === */
.section-container {
    max-width: 80rem;
    margin: 0 auto;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}
