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

:root {
    --off-beige: #f5f5f0;
    --dark-charcoal: #1a1a1a;
    --dark-charcoal-alpha-15: rgba(26, 26, 26, 0.15);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--off-beige);
    color: var(--dark-charcoal);
    overflow: hidden;
    height: 100vh;
}

.bg-off-beige {
    background-color: var(--off-beige);
}

.text-dark-charcoal {
    color: var(--dark-charcoal);
}

/* Top Button */
.top-button {
    display: flex;
    align-items: center;
    border-radius: 9999px;
    font-family: serif;
    width: fit-content;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 1.5rem;
    color: var(--dark-charcoal);
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.2s;
}

.top-button:focus-visible {
    outline: none;
    ring: 2px;
    ring-offset: 2px;
    ring-color: var(--dark-charcoal);
    ring-offset-color: white;
}

.top-button .divider {
    align-self: stretch;
    background: rgba(255, 255, 255, 0.1);
    width: 1px;
}

.top-button .font-serif {
    font-family: serif;
    padding: 0.25rem 0;
}

.top-button .italic {
    font-style: italic;
}

/* Border styling */
.border-y-dark-charcoal-alpha-15 {
    border-top: 1px solid var(--dark-charcoal-alpha-15);
    border-bottom: 1px solid var(--dark-charcoal-alpha-15);
}

@media (min-width: 768px) {
    .md\:border-transparent {
        border-color: transparent;
    }
    .md\:pt-\[32px\] {
        padding-top: 32px;
    }
}

/* Draggable Pills */
.pill {
    position: absolute;
    touch-action: none;
    user-select: none;
    cursor: grab;
    z-index: 30;
    will-change: transform;
    perspective: 1000px;
    transition: transform 0.1s ease-out;
}

.pill:active {
    cursor: grabbing;
    transform: scale(0.95);
}

.pill:hover {
    transform: translateZ(10px) scale(1.02);
}

.pill-shape {
    pointer-events: none;
}

.pill-beige {
    width: 70px;
    height: 75px;
    background: linear-gradient(135deg, #f0f0e8 0%, #d4d4c8 50%, #c0c0b4 100%);
    border-radius: 35px 35px 35px 0;
    box-shadow: 
        0 8px 16px rgba(0, 0, 0, 0.15),
        0 4px 8px rgba(0, 0, 0, 0.1),
        inset 0 2px 4px rgba(255, 255, 255, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    transform-style: preserve-3d;
    transform: rotateY(-5deg) rotateX(2deg);
}

.pill-beige::before {
    content: '';
    position: absolute;
    top: 10%;
    left: 15%;
    width: 30%;
    height: 25%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.pill-orange {
    width: 120px;
    height: 120px;
    background: radial-gradient(circle at 30% 30%, #ffb366 0%, #ff8c42 40%, #ff6b1a 100%);
    border-radius: 50%;
    box-shadow: 
        0 12px 24px rgba(255, 140, 66, 0.4),
        0 6px 12px rgba(255, 140, 66, 0.3),
        inset 0 4px 8px rgba(255, 255, 255, 0.2),
        inset 0 -4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    transform-style: preserve-3d;
    transform: rotateY(8deg) rotateX(-3deg);
}

.pill-orange::before {
    content: '';
    position: absolute;
    top: 20%;
    left: 25%;
    width: 35%;
    height: 35%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.5) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.pill-red {
    width: 120px;
    height: 45px;
    background: linear-gradient(135deg, #ff6666 0%, #ff4444 50%, #cc0000 100%);
    border-radius: 22px;
    box-shadow: 
        0 8px 16px rgba(255, 68, 68, 0.4),
        0 4px 8px rgba(255, 68, 68, 0.3),
        inset 0 2px 4px rgba(255, 255, 255, 0.2),
        inset 0 -2px 4px rgba(0, 0, 0, 0.2);
    position: relative;
    transform-style: preserve-3d;
    transform: rotateY(-3deg) rotateX(1deg);
}

.pill-red::before {
    content: '';
    position: absolute;
    top: 15%;
    left: 20%;
    width: 25%;
    height: 40%;
    background: radial-gradient(ellipse, rgba(255, 255, 255, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.pill-1 {
    left: 259px;
    top: 278px;
}

.pill-2 {
    left: 800px;
    top: 200px;
}

.pill-3 {
    left: 173px;
    top: 714px;
}

/* Loading Box Section */
.loading-box {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 2px solid rgba(26, 26, 26, 0.1);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    min-width: 400px;
    max-width: 500px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    text-align: center;
    position: relative;
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid rgba(26, 26, 26, 0.1);
    border-top-color: var(--dark-charcoal);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 2rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

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

.loading-message {
    font-family: serif;
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--dark-charcoal);
    line-height: 1.4;
    margin: 0;
}

.bitcoin-price {
    font-family: 'Courier New', Courier, monospace;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--dark-charcoal);
    margin: 0;
    padding: 0.75rem 1rem;
    background: rgba(26, 26, 26, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(26, 26, 26, 0.1);
}

@media (min-width: 768px) {
    .loading-box {
        padding: 4rem 3rem;
        min-width: 500px;
    }
    
    .loading-message {
        font-size: 1.75rem;
    }
    
    .bitcoin-price {
        font-size: 1.5rem;
    }
}

/* Utility Classes */
.relative {
    position: relative;
}

.h-screen {
    height: 100vh;
}

.overflow-hidden {
    overflow: hidden;
}

.pb-8 {
    padding-bottom: 2rem;
}

.z-20 {
    z-index: 20;
}

.z-10 {
    z-index: 10;
}

.py-\[18px\] {
    padding-top: 18px;
    padding-bottom: 18px;
}

.flex {
    display: flex;
}

.items-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

.absolute {
    position: absolute;
}

.inset-0 {
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
}

.flex-col {
    flex-direction: column;
}

.pointer-events-none {
    pointer-events: none;
}

.transition-all {
    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 300ms;
}

.duration-300 {
    transition-duration: 300ms;
}
