@font-face {
    font-family: 'Ubuntu';
    src: url('Ubuntu-BoldItalic.ttf') format('truetype');
    font-weight: bold;
    font-style: italic;
    font-display: swap;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Ubuntu', 'Arial', sans-serif;
    background: #000000;
    color: #ffffff;
    line-height: 1.6;
    position: relative;
    overflow-x: hidden;
}

/* Animated Blood Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, #000000 0%, #1a0000 50%, #330000 100%);
    z-index: -2;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(8px 12px at 15% 20%, rgba(220, 47, 47, 0.9), rgba(180, 30, 30, 0.7) 40%, transparent 70%),
        radial-gradient(6px 10px at 35% 60%, rgba(180, 30, 30, 0.8), rgba(160, 25, 25, 0.6) 40%, transparent 70%),
        radial-gradient(10px 15px at 55% 10%, rgba(255, 68, 68, 0.7), rgba(200, 40, 40, 0.5) 40%, transparent 70%),
        radial-gradient(7px 11px at 75% 40%, rgba(200, 40, 40, 0.8), rgba(170, 35, 35, 0.6) 40%, transparent 70%),
        radial-gradient(9px 14px at 85% 70%, rgba(160, 25, 25, 0.9), rgba(140, 20, 20, 0.7) 40%, transparent 70%),
        radial-gradient(5px 8px at 25% 80%, rgba(190, 35, 35, 0.8), rgba(150, 25, 25, 0.6) 40%, transparent 70%),
        radial-gradient(11px 16px at 65% 85%, rgba(210, 40, 40, 0.7), rgba(170, 30, 30, 0.5) 40%, transparent 70%),
        radial-gradient(4px 7px at 45% 25%, rgba(240, 60, 60, 0.6), rgba(180, 40, 40, 0.4) 40%, transparent 70%),
        linear-gradient(180deg, transparent 0%, rgba(220, 47, 47, 0.15) 50%, rgba(180, 30, 30, 0.25) 100%);
    background-size: 
        150px 200px,
        180px 240px,
        120px 160px,
        200px 260px,
        140px 180px,
        160px 210px,
        110px 140px,
        190px 250px,
        100% 100%;
    animation: bloodDrip 12s infinite linear;
    z-index: -1;
}

@keyframes bloodDrip {
    0% {
        background-position: 
            0% -20%,
            0% -15%,
            0% -25%,
            0% -10%,
            0% -30%,
            0% -18%,
            0% -22%,
            0% -12%,
            0% 0%;
    }
    100% {
        background-position: 
            0% 120%,
            0% 125%,
            0% 115%,
            0% 130%,
            0% 110%,
            0% 135%,
            0% 118%,
            0% 128%,
            0% 50%;
    }
}

/* Header */
.header {
    background: rgba(220, 47, 47, 0.95);
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(220, 47, 47, 0.3);
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
}

.nav {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-size: 1.8em;
    font-weight: bold;
    font-style: italic;
    color: #ffffff;
    letter-spacing: 1px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.logo-img {
    height: 40px;
    width: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.logo span {
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-weight: bold;
    font-style: italic;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-links a {
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 600;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.nav-links a:hover {
    color: #000000;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
    transform: translateY(-1px);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    padding-top: 100px; /* Add padding to account for fixed header */
}

.hero::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="2" fill="%23dc2f2f" opacity="0.1"/></svg>') repeat;
    animation: float 20s infinite linear;
}

@keyframes float {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 0 20px;
}

.hero-logo {
    text-align: center;
    margin-bottom: 30px;
}

.hero-logo-img {
    max-width: 300px;
    height: auto;
    max-height: 200px;
    filter: drop-shadow(0 4px 8px rgba(220, 47, 47, 0.5));
}

.hero h1 {
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-size: 4em;
    font-weight: bold;
    font-style: italic;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #dc2f2f, #ff4444);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(220, 47, 47, 0.3);
    letter-spacing: 2px;
}

.hero-subtitle {
    font-size: 2.5em;
    margin-bottom: 30px;
    color: #cccccc;
}

.cta-button, .upload-btn, .action-btn {
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-weight: bold;
    font-style: italic;
    letter-spacing: 0.5px;
}

.cta-button {
    background: linear-gradient(45deg, #dc2f2f, #b32727);
    color: white;
    padding: 15px 40px;
    border: none;
    border-radius: 50px;
    font-size: 1.2em;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    display: inline-block;
    white-space: nowrap;
    line-height: 1.2;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(220, 47, 47, 0.4);
}

/* Contract Address Box - Compact with side-by-side layout */
.contract-box {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #dc2f2f;
    border-radius: 10px;
    padding: 15px;
    margin: 20px auto 30px auto;
    max-width: 550px;
    text-align: left;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(220, 47, 47, 0.3);
}

.contract-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(220, 47, 47, 0.1), transparent);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.contract-label {
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-weight: bold;
    font-style: italic;
    color: #dc2f2f;
    font-size: 1em;
    margin-bottom: 8px;
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.contract-address-container {
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
    z-index: 2;
}

.contract-address {
    font-family: 'Courier New', monospace;
    background: rgba(0, 0, 0, 0.3);
    padding: 10px 12px;
    border-radius: 6px;
    color: #ffffff;
    font-size: 0.9em;
    word-break: break-all;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    flex: 1;
}

.contract-address:hover {
    background: rgba(0, 0, 0, 0.5);
    border-color: #dc2f2f;
    transform: scale(1.01);
}

.copy-button {
    background: linear-gradient(45deg, #dc2f2f, #b32727);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-weight: bold;
    font-size: 0.85em;
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
    white-space: nowrap;
    min-width: 60px;
}

.copy-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(220, 47, 47, 0.4);
}

.copy-success {
    color: #00ff00;
    font-size: 0.8em;
    margin-top: 8px;
    opacity: 0;
    transition: opacity 0.3s ease;
    position: relative;
    z-index: 2;
    text-align: center;
}

.copy-success.show {
    opacity: 1;
}

/* Social Links */
.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 30px 0 40px 0;
    align-items: center;
}

.social-link {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    padding: 15px;
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.5em;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    flex-shrink: 0;
}

.social-link:hover {
    background: #dc2f2f;
    border-color: #ffffff;
    transform: translateY(-3px) scale(1.1);
}

/* Share Your Fail Section - Dark background to separate it */
#create {
    background: rgba(0, 0, 0, 0.7);
    border-radius: 20px;
    margin: 40px auto;
    max-width: 1200px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(220, 47, 47, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

#create h2 {
    margin-top: 0;
    padding-top: 20px;
}

#create .section {
    padding: 60px 40px;
}

/* Sections */
.section {
    padding: 80px 0;
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
}

.section h2 {
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-size: 2.5em;
    font-weight: bold;
    font-style: italic;
    text-align: center;
    margin-bottom: 50px;
    color: #dc2f2f;
    letter-spacing: 1px;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

.feature-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(220, 47, 47, 0.2);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(220, 47, 47, 0.2);
}

.feature-icon {
    font-size: 3em;
    margin-bottom: 20px;
    color: #dc2f2f;
}

.feature-card h3 {
    font-family: 'Ubuntu', 'Arial', sans-serif;
    font-weight: bold;
    font-style: italic;
    margin-bottom: 15px;
    color: #ffffff;
    letter-spacing: 0.5px;
}

/* Watermarking Tool - Adjust for new background */
.watermark-tool {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    padding: 30px;
    margin: 40px 0 20px 0;
    border: 2px solid rgba(220, 47, 47, 0.2);
}

.upload-section {
    background: rgba(220, 47, 47, 0.1);
    border: 3px dashed #dc2f2f;
    border-radius: 15px;
    padding: 40px;
    text-align: center;
    margin-bottom: 30px;
    transition: all 0.3s ease;
}

.upload-section:hover {
    border-color: #ff4444;
    background: rgba(220, 47, 47, 0.15);
}

.upload-section.dragover {
    border-color: #00ff00;
    background: rgba(0, 255, 0, 0.1);
}

.upload-btn {
    background: linear-gradient(45deg, #dc2f2f, #b32727);
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 50px;
    font-size: 1.1em;
    cursor: pointer;
    transition: transform 0.3s ease;
    margin: 10px;
}

.upload-btn:hover {
    transform: translateY(-2px);
}

.file-input {
    display: none;
}

.controls {
    display: none;
    background: rgba(0, 0, 0, 0.3);
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 30px;
}

.control-row {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.control-group {
    flex: 1;
    min-width: 200px;
}

.control-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #dc2f2f;
}

.control-group input[type="range"] {
    width: 100%;
    margin-bottom: 5px;
}

.range-value {
    font-size: 0.9em;
    color: #cccccc;
}

.position-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    max-width: 300px;
}

.position-btn {
    padding: 10px;
    border: 2px solid #444;
    border-radius: 5px;
    cursor: pointer;
    text-align: center;
    font-size: 0.9em;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
}

.position-btn:hover {
    border-color: #dc2f2f;
}

.position-btn.active {
    background: #dc2f2f;
    color: white;
    border-color: #dc2f2f;
}

.preview-section {
    display: none;
    text-align: center;
    margin-bottom: 30px;
}

.video-container {
    position: relative;
    display: inline-block;
    background: #000;
    border-radius: 10px;
    overflow: hidden;
}

#videoPreview {
    max-width: 100%;
    max-height: 500px;
    display: block;
}

.watermark-overlay {
    position: absolute;
    pointer-events: none;
    z-index: 10;
}

.processing {
    display: none;
    text-align: center;
    margin: 20px 0;
}

.spinner {
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid #dc2f2f;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.action-buttons {
    text-align: center;
    margin-top: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.action-btn {
    background: linear-gradient(45deg, #00cc44, #009933);
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 50px;
    font-size: 1.1em;
    cursor: pointer;
    transition: transform 0.3s ease;
    white-space: nowrap;
    line-height: 1.2;
    flex-shrink: 0;
}

.action-btn:hover {
    transform: translateY(-2px);
}

.action-btn:disabled {
    background: #666;
    cursor: not-allowed;
    transform: none;
}

.status-message {
    text-align: center;
    padding: 10px;
    margin: 10px 0;
    border-radius: 5px;
    display: none;
}

.status-success {
    background: rgba(0, 255, 0, 0.2);
    color: #00ff00;
    border: 1px solid #00cc00;
}

.status-error {
    background: rgba(220, 47, 47, 0.2);
    color: #dc2f2f;
    border: 1px solid #dc2f2f;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #2d5a2d 0%, #1a4d1a 50%, #0d330d 100%);
    padding: 40px 0;
    text-align: center;
    margin-top: 50px;
    border-top: 3px solid rgba(45, 90, 45, 0.5);
    box-shadow: 0 -4px 20px rgba(45, 90, 45, 0.2);
}

.footer p {
    color: #cccccc;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.footer .social-links .social-link {
    background: rgba(45, 90, 45, 0.3);
    border: 2px solid #2d5a2d;
}

.footer .social-links .social-link:hover {
    background: #2d5a2d;
    border-color: #ffffff;
    transform: translateY(-3px) scale(1.1);
}

/* Mobile responsiveness for the new section background */
@media (max-width: 768px) {
    .hero {
        padding-top: 120px; /* More padding for mobile */
    }
    
    .logo-img {
        height: 35px;
    }

    .hero-logo-img {
        max-width: 200px;
        max-height: 150px;
    }

    .hero h1 {
        font-size: 2.5em;
    }
    
    .hero-subtitle {
        font-size: 1.2em;
    }
    
    .nav-links {
        display: none;
    }
    
    .control-row {
        flex-direction: column;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .contract-box {
        margin: 20px 10px 30px 10px;
        padding: 12px;
        max-width: calc(100% - 20px);
    }

    .contract-address {
        font-size: 0.8em;
        padding: 8px 10px;
    }

    .copy-button {
        padding: 8px 12px;
        font-size: 0.8em;
        min-width: 55px;
    }

    .social-links {
        flex-wrap: wrap;
        gap: 15px;
    }

    #create {
        margin: 20px 10px;
        border-radius: 15px;
    }
    
    #create .section {
        padding: 40px 20px;
    }
    
    .watermark-tool {
        padding: 20px;
        margin: 30px 0 15px 0;
    }

    .upload-section {
        padding: 30px 20px;
    }

    .section {
        padding: 60px 10px;
    }

    .position-grid {
        grid-template-columns: repeat(2, 1fr);
        max-width: 250px;
        margin: 0 auto;
    }

    .hero-content {
        padding: 0 10px;
    }

    .cta-button {
        font-size: 1em;
        padding: 12px 25px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding-top: 140px; /* Even more padding for small screens */
    }
    
    .logo-img {
        height: 30px;
    }

    .hero-logo-img {
        max-width: 150px;
        max-height: 100px;
    }

    .hero h1 {
        font-size: 2em;
    }

    .section h2 {
        font-size: 2em;
    }

    .contract-address-container {
        flex-direction: column;
        gap: 8px;
    }

    .contract-address {
        text-align: center;
    }

    .copy-button {
        align-self: center;
        min-width: 80px;
    }

    #create {
        margin: 15px 5px;
        border-radius: 10px;
    }
    
    #create .section {
        padding: 30px 15px;
    }

    .position-grid {
        grid-template-columns: 1fr;
        max-width: 200px;
    }

    .feature-card {
        padding: 20px;
    }

    .logo {
        font-size: 1.5em;
    }
}