@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;700;900&family=Inter:wght@300;400;600&display=swap');

:root {
    --bg-color: #050505;
    --card-bg: rgba(20, 20, 20, 0.7);
    --blood-red: #8b0000;
    --bright-red: #ff3131;
    --gold: #c5a059;
    --text-main: #e0e0e0;
    --text-dim: #a0a0a0;
    --spacing: 2rem;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    background-image: 
        radial-gradient(circle at 50% -20%, rgba(139, 0, 0, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 0% 100%, rgba(139, 0, 0, 0.05) 0%, transparent 40%);
}

/* Logo Section */
.logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2rem;
    position: relative;
}

.logo-svg {
    width: 80px;
    height: 80px;
    filter: drop-shadow(0 0 10px rgba(255, 49, 49, 0.3));
}

.neon-circle {
    filter: drop-shadow(0 0 5px #ff3131);
    animation: pulse-neon 2s infinite alternate;
}

.neon-arrow {
    filter: drop-shadow(0 0 8px #ff3131);
    stroke-dasharray: 200;
    stroke-dashoffset: 200;
    animation: draw-arrow 1.5s ease-out forwards;
}

@keyframes pulse-neon {
    from { opacity: 0.7; filter: drop-shadow(0 0 2px #ff3131); }
    to { opacity: 1; filter: drop-shadow(0 0 10px #ff3131); }
}

@keyframes draw-arrow {
    to { stroke-dashoffset: 0; }
}

.logo-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-family: 'Cinzel', serif;
    margin-top: -10px;
}

.logo-text .small-text {
    font-size: 0.7rem;
    letter-spacing: 5px;
    color: var(--text-dim);
}

.logo-text .big-text {
    font-size: 1.2rem;
    font-weight: 900;
    color: #fff;
    letter-spacing: 3px;
    background: linear-gradient(to bottom, #fff, #a0a0a0);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 4rem 1.5rem;
}

/* Typography */
h1, h2, h3 {
    font-family: 'Cinzel', serif;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.glitch-text {
    font-size: 3.5rem;
    font-weight: 900;
    text-align: center;
    color: var(--text-main);
    text-shadow: 0 0 20px rgba(255, 49, 49, 0.4);
    margin-bottom: 0.5rem;
    position: relative;
}

.subtitle {
    text-align: center;
    color: var(--blood-red);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 4rem;
    text-transform: uppercase;
    letter-spacing: 4px;
}

/* Sections */
.intro {
    text-align: center;
    margin-bottom: 5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.intro p {
    font-size: 1.1rem;
    color: var(--text-dim);
    font-style: italic;
}

/* Martial Laws Grid */
.laws-grid {
    display: grid;
    gap: 3rem;
    margin-bottom: 5rem;
}

.law-card {
    background: var(--card-bg);
    border: 1px solid rgba(139, 0, 0, 0.2);
    padding: 2.5rem;
    border-radius: 4px;
    position: relative;
    backdrop-filter: blur(10px);
    transition: var(--transition);
    cursor: default;
}

.law-card:hover {
    border-color: var(--blood-red);
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(139, 0, 0, 0.1);
}

.law-number {
    position: absolute;
    top: -20px;
    left: 20px;
    background: var(--blood-red);
    color: white;
    font-family: 'Cinzel', serif;
    padding: 0.5rem 1.5rem;
    font-weight: 900;
    font-size: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.law-card h3 {
    margin-top: 1rem;
    margin-bottom: 1.5rem;
    color: var(--bright-red);
    font-size: 1.8rem;
}

.law-card p {
    color: var(--text-main);
}

.law-card ul {
    list-style: none;
    margin-top: 1.5rem;
}

.law-card li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--text-dim);
    font-size: 0.95rem;
}

.law-card li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--blood-red);
}

/* Mission Section */
.mission-box {
    background: linear-gradient(145deg, #101010, #050505);
    border-left: 4px solid var(--blood-red);
    padding: 3rem;
    margin-bottom: 5rem;
}

.mission-box h2 {
    margin-bottom: 2rem;
    color: var(--text-main);
}

/* Name Entry */
.name-entry {
    margin-bottom: 2.5rem;
    border-bottom: 1px solid rgba(139, 0, 0, 0.3);
    padding-bottom: 0.5rem;
}

.name-entry label {
    display: block;
    font-family: 'Cinzel', serif;
    font-size: 0.8rem;
    color: var(--blood-red);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
}

.name-entry input {
    background: transparent;
    border: none;
    width: 100%;
    color: #fff;
    font-size: 1.5rem;
    font-family: 'Inter', sans-serif;
    outline: none;
}

.name-entry input::placeholder {
    color: rgba(255, 255, 255, 0.1);
}

.checklist {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.check-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
    user-select: none;
}

.check-item input {
    display: none;
}

.custom-checkbox {
    width: 24px;
    height: 24px;
    border: 2px solid var(--blood-red);
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
}

.check-item input:checked + .custom-checkbox {
    background: var(--blood-red);
}

.check-item input:checked + .custom-checkbox::after {
    content: '✓';
    color: white;
    font-weight: bold;
}

.check-item span {
    font-size: 1.1rem;
}

.check-item small {
    display: block;
    color: var(--text-dim);
    font-size: 0.85rem;
}

/* Warnings */
.warning-panel {
    background: rgba(139, 0, 0, 0.05);
    border: 1px dashed rgba(139, 0, 0, 0.3);
    padding: 2rem;
    text-align: center;
    margin-bottom: 5rem;
}

.warning-panel h4 {
    color: var(--gold);
    margin-bottom: 1rem;
}

/* Signature */
.signature-area {
    text-align: center;
    padding-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-sign {
    background: var(--blood-red);
    color: white;
    border: none;
    padding: 1.5rem 4rem;
    font-family: 'Cinzel', serif;
    font-weight: 900;
    font-size: 1.5rem;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 3px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    opacity: 0.6;
}

.btn-sign.active {
    opacity: 1;
    box-shadow: 0 0 30px rgba(139, 0, 0, 0.6);
}

.btn-sign:hover {
    background: var(--bright-red);
    transform: scale(1.05);
}

.btn-sign::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300%;
    height: 300%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.2) 0%, transparent 60%);
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.6s ease;
}

.btn-sign:active::after {
    transform: translate(-50%, -50%) scale(1);
}

.btn-export {
    background: transparent;
    border: 1px solid var(--gold);
    color: var(--gold);
    padding: 1rem 2rem;
    font-family: 'Cinzel', serif;
    font-size: 0.9rem;
    margin-top: 2rem;
    cursor: pointer;
    letter-spacing: 2px;
    transition: var(--transition);
}

.btn-export:hover {
    background: var(--gold);
    color: #000;
}

/* Lean Contract Certificate (Hidden from view, visible for capture) */
.lean-contract {
    position: absolute;
    left: -9999px;
    top: 0;
    width: 600px;
    height: 800px;
    background: #050505;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    box-sizing: border-box;
}

.lean-content {
    width: 100%;
    height: 100%;
    border: 2px solid #8b0000;
    background: radial-gradient(circle at center, #101010 0%, #050505 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px;
    position: relative;
    border-radius: 4px;
}

.lean-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #fff;
}

.law-title {
    color: #8b0000;
    letter-spacing: 5px;
    font-size: 0.7rem;
    margin-bottom: 4rem;
}

.sig-line {
    width: 300px;
    height: 1px;
    background: rgba(255, 255, 255, 0.3);
    margin-bottom: 1rem;
}

.signer-name {
    font-family: 'Cinzel', serif;
    font-size: 2rem;
    color: var(--gold);
    margin-bottom: 0.5rem;
    min-height: 2.5rem;
}

.sign-date {
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-bottom: 4rem;
}

.motto {
    font-style: italic;
    color: var(--text-dim);
    font-size: 0.9rem;
}

.logo-container.sm .logo-svg {
    width: 80px;
    height: 80px;
    margin-bottom: 2rem;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: #101010;
    color: var(--bright-red);
    border: 1px solid var(--bright-red);
    padding: 1rem 2rem;
    font-family: 'Cinzel', serif;
    font-size: 0.9rem;
    letter-spacing: 1px;
    z-index: 1000;
    box-shadow: 0 0 20px rgba(255, 49, 49, 0.4);
    transition: bottom 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    white-space: nowrap;
    border-radius: 4px;
}

.toast.show {
    bottom: 30px;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .glitch-text { font-size: 2.2rem; }
    .law-card { padding: 1.5rem; }
    .law-number { font-size: 1.2rem; top: -15px; }

    .logo-svg {
        width: 60px;
        height: 60px;
    }
    
    .logo-text .big-text {
        font-size: 1rem;
    }
    
    .logo-text .small-text {
        font-size: 0.6rem;
    }

    .laws-grid {
        gap: 1.5rem;
    }
}
