/* reset simple */
* { box-sizing: border-box; margin: 0; padding: 0; }
html,body {
    height: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-attachment: fixed;
    color:#111;
}

/* layout */
header {
    padding: 24px 20px;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.2);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}
header h1 {
    font-size: 28px;
    font-weight:700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

main { max-width: 1000px; margin: 32px auto; padding: 0 20px; }

.card-panel {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    animation: fadeInUp 0.5s ease;
}
.center { text-align:center; }

label {
    display:block;
    margin-bottom:12px;
    color:#2d3748;
    font-weight:600;
    font-size: 16px;
}
input[type="text"] {
    width:100%;
    padding:14px 16px;
    border-radius:12px;
    border:2px solid #e2e8f0;
    font-size:16px;
    margin-bottom:16px;
    transition: all 0.3s ease;
    background: white;
}
input[type="text"]:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102,126,234,0.1);
}

.row { display:flex; gap:12px; justify-content:center; margin-top:12px; }
.btn {
    padding:14px 28px;
    border-radius:12px;
    border: none;
    cursor:pointer;
    background:#f7fafc;
    font-weight:600;
    font-size: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.btn.primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    box-shadow: 0 8px 24px rgba(102,126,234,0.3);
}
.btn.primary:hover {
    box-shadow: 0 12px 32px rgba(102,126,234,0.4);
}

/* duel */
.duel-row {
    display:flex;
    align-items:center;
    justify-content:center;
    gap:32px;
    margin-top:24px;
    flex-wrap:wrap;
}
.choice-card {
    width:300px;
    border-radius:20px;
    background: rgba(255,255,255,0.95);
    padding:16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border:2px solid rgba(255,255,255,0.5);
    cursor:pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fadeInScale 0.5s ease;
}
.choice-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 50px rgba(102,126,234,0.3);
    border-color: #667eea;
}
.choice-card:active {
    transform: translateY(-4px) scale(0.98);
}
.img-wrap {
    width:100%;
    min-height:200px;
    max-height:400px;
    display:flex;
    align-items:center;
    justify-content:center;
    border-radius:16px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border:2px solid rgba(0,0,0,0.05);
    position: relative;
}
.img-wrap::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, transparent 0%, rgba(0,0,0,0.02) 100%);
    pointer-events: none;
}
.img-wrap.big {
    width:380px;
    height:380px;
    margin: 16px auto;
}
img {
    width:100%;
    height:auto;
    object-fit:contain;
    display:block;
    border-radius:12px;
}

/* text */
.card-name {
    margin-top:16px;
    font-weight:700;
    font-size:18px;
    text-align:center;
    color:#2d3748;
}
.vs {
    font-weight:900;
    font-size:32px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: pulse 2s ease-in-out infinite;
}

/* result */
.winner-card {
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:16px;
    margin:20px 0;
}
#result h2 {
    font-size: 32px;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* misc */
.hidden { display:none; }
.muted { color:#718096; font-size: 14px; margin-top: 8px; }
.small {
    font-size:13px;
    color: rgba(255,255,255,0.8);
    padding:20px 16px;
    text-align:center;
}
.status {
    margin-top:12px;
    color:#e53e3e;
    min-height:24px;
    font-weight:500;
}

/* animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ads */
.ad-banner-top {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px;
    background: rgba(255,255,255,0.95);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    min-height: 110px;
}

.ad-sidebar {
    position: fixed;
    top: 120px;
    width: 180px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    z-index: 10;
}

.ad-sidebar-left {
    left: 20px;
}

.ad-sidebar-right {
    right: 20px;
}

.ad-placeholder {
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(240,240,240,0.8);
    border: 2px dashed #ccc;
    border-radius: 8px;
    color: #999;
    font-size: 12px;
    padding: 20px;
    text-align: center;
    min-height: 90px;
}

.ad-sidebar .ad-placeholder {
    min-height: 600px;
}

/* responsive */
@media (max-width:720px) {
  .choice-card { width:42vw; }
  .img-wrap { height:42vw; }
  .vs { font-size: 24px; }
  .duel-row { gap: 16px; }

  /* Hide sidebars on mobile */
  .ad-sidebar {
    display: none;
  }
}

/* responsive tablet */
@media (max-width:1280px) {
  /* Hide sidebars on tablets too */
  .ad-sidebar {
    display: none;
  }
}

/* Social Sharing Buttons */
.share-buttons-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
}

.share-cta {
    font-weight: 700;
    color: #4a5568;
    margin-bottom: 8px;
}

.social-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    font-size: 14px;
    color: white;
    transition: transform 0.2s, box-shadow 0.2s;
}

.social-btn .icon {
    font-size: 18px;
}

.social-btn.reddit {
    background: #ff4500; /* Reddit Orange */
}
.social-btn.reddit:hover {
    background: #e03d00;
    box-shadow: 0 4px 12px rgba(255, 69, 0, 0.3);
}

.social-btn.twitter {
    background: #000000; /* X Black */
}
.social-btn.twitter:hover {
    background: #333333;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.social-btn.whatsapp {
    background: #25d366; /* WhatsApp Green */
}
.social-btn.whatsapp:hover {
    background: #128c7e;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.social-btn.copy {
    background: #718096; /* Neutral Gray */
}
.social-btn.copy:hover {
    background: #4a5568;
    box-shadow: 0 4px 12px rgba(113, 128, 150, 0.3);
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 14px;
    z-index: 1000;
    animation: fadeInOut 3s ease forwards;
}

@keyframes fadeInOut {
    0% { opacity: 0; transform: translate(-50%, 20px); }
    10% { opacity: 1; transform: translate(-50%, 0); }
    90% { opacity: 1; transform: translate(-50%, 0); }
    100% { opacity: 0; transform: translate(-50%, -20px); }
}
