:root {
    --primary: #8a5cf5;
    --primary-dark: #6d3dc7;
    --secondary: #ffd166;
    --dark: #0f0e13;
    --darker: #09080c;
    --light: #f8f9fa;
    --gray: #6c757d;
    --success: #4cc9f0;
    --danger: #f72585;
    --border-radius: 16px;
    --shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
    --transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.1);
    --coin-gradient: radial-gradient(circle at 50% 50%, #f5f7fa 0%, #e4e7f1 100%);
    --coin-gold: linear-gradient(135deg, #ffd700 0%, #daa520 50%, #b8860b 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
}

.main-container {
    background: var(--dark);
    color: var(--light);
    line-height: 1.6;
    min-height: 100vh;
    padding: 20px;
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(138, 92, 245, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(255, 209, 102, 0.15) 0%, transparent 50%);
    overflow-x: hidden;
}

.container {
    width: 95%;
    margin: 0 auto;
}

.header-title {
    text-align: center;
    padding: 40px 20px;
    position: relative;
    overflow: hidden;
}

h1 {
    font-size: 3rem;
    margin-bottom: 15px;
    font-family: 'Playfair Display', serif;
    background: linear-gradient(90deg, var(--secondary), var(--primary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 700;
    position: relative;
    z-index: 2;
}

.subtitle {
    font-size: 1.2rem;
    color: var(--gray);
    max-width: 700px;
    margin: 0 auto 30px;
    position: relative;
    z-index: 2;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

@media (max-width: 900px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

/* Sección de la moneda */
.coin-section {
    background: rgba(15, 14, 19, 0.7);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 30px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.coin-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(138, 92, 245, 0.1) 0%, transparent 70%);
    z-index: -1;
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    
    100% { transform: rotate(360deg); }
}

.coin-container {
    position: relative;
    width: 100%;
    height: 300px;
    perspective: 1000px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.coin {
    width: 150px;
    height: 150px;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 1s ease-out;
    cursor: pointer;
}

.coin-front, .coin-back {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    backface-visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2rem;
    font-weight: bold;
    box-shadow: 
        inset 0 0 15px rgba(0, 0, 0, 0.2),
        0 10px 25px rgba(0, 0, 0, 0.3);
    background: var(--coin-gold);
    border: 8px solid #daa520;
}

.coin-front {
    background: var(--coin-gold);
    transform: rotateY(0deg);
}

.coin-back {
    background: var(--coin-gold);
    transform: rotateY(180deg);
}

.coin-edge {
    position: absolute;
    width: 100%;
    height: 10px;
    background: linear-gradient(90deg, #b8860b, #daa520, #b8860b);
    border-radius: 5px;
    top: 50%;
    transform: translateY(-50%) rotateX(90deg);
}

.coin-text {
    color: #000;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.5);
    user-select: none;
}

.flip-btn {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    display: block;
    margin: 30px auto 0;
    font-size: 1.1rem;
    box-shadow: 0 5px 15px rgba(138, 92, 245, 0.4);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.flip-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    z-index: -1;
    opacity: 0;
    transition: var(--transition);
}

.flip-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(138, 92, 245, 0.6);
}

.flip-btn:hover::before {
    opacity: 1;
}

.flip-btn:active {
    transform: translateY(1px);
}

.flip-btn i {
    margin-right: 10px;
}

/* Panel de control */
.control-panel {
    background: rgba(15, 14, 19, 0.7);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 30px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.mode-selector {
    margin-bottom: 30px;
}

.mode-selector h3 {
    margin-bottom: 15px;
    color: var(--secondary);
    display: flex;
    align-items: center;
}

.mode-selector h3 i {
    margin-right: 10px;
}

.mode-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
}

.mode-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--light);
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    font-weight: 500;
}

.mode-btn:hover {
    background: rgba(138, 92, 245, 0.2);
    border-color: var(--primary);
}

.mode-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    box-shadow: 0 0 0 2px rgba(138, 92, 245, 0.5);
}

.custom-options {
    margin-top: 20px;
    display: none;
}

.custom-options.active {
    display: block;
}

.option-input {
    display: flex;
    margin-bottom: 10px;
}

.option-input input {
    flex: 1;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px 0 0 8px;
    color: var(--light);
    transition: var(--transition);
}

.option-input input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(138, 92, 245, 0.3);
}

.option-input button {
    padding: 0 15px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    transition: var(--transition);
}

.option-input button:hover {
    background: var(--primary-dark);
}

.options-list {
    margin-top: 15px;
    max-height: 150px;
    overflow-y: auto;
}

.option-tag {
    display: inline-flex;
    align-items: center;
    background: rgba(138, 92, 245, 0.2);
    color: var(--light);
    padding: 8px 12px;
    border-radius: 20px;
    margin-right: 8px;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.option-tag .remove-option {
    margin-left: 8px;
    cursor: pointer;
    color: var(--danger);
    font-size: 0.8rem;
}

/* Configuración */
.settings {
    margin-top: 30px;
}

.settings h3 {
    margin-bottom: 15px;
    color: var(--secondary);
    display: flex;
    align-items: center;
}

.settings h3 i {
    margin-right: 10px;
}

.setting-option {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.setting-option input[type="checkbox"] {
    appearance: none;
    width: 40px;
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    position: relative;
    cursor: pointer;
    margin-right: 10px;
    transition: var(--transition);
}

.setting-option input[type="checkbox"]:checked {
    background: var(--primary);
}

.setting-option input[type="checkbox"]::before {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    background: white;
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: var(--transition);
}

.setting-option input[type="checkbox"]:checked::before {
    left: 22px;
}

.setting-option label {
    cursor: pointer;
    user-select: none;
}

/* Resultados */
.results {
    margin-top: 30px;
}

.results h3 {
    margin-bottom: 15px;
    color: var(--secondary);
    display: flex;
    align-items: center;
}

.results h3 i {
    margin-right: 10px;
}

.result-display {
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius);
    padding: 20px;
    text-align: center;
    margin-bottom: 20px;
    min-height: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.result-text {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--secondary);
}

.result-description {
    color: var(--gray);
    font-size: 0.9rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 15px;
}

.stat-box {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 15px;
    text-align: center;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--gray);
}

/* Historial */
.history {
    margin-top: 30px;
}

.history h3 {
    margin-bottom: 15px;
    color: var(--secondary);
    display: flex;
    align-items: center;
}

.history h3 i {
    margin-right: 10px;
}

.history-items {
    max-height: 200px;
    overflow-y: auto;
    padding-right: 10px;
}

.history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    margin-bottom: 8px;
    transition: var(--transition);
}

.history-item:hover {
    background: rgba(138, 92, 245, 0.1);
}

.history-result {
    display: flex;
    align-items: center;
}

.history-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--coin-gold);
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 10px;
    font-size: 0.7rem;
    font-weight: bold;
    color: #000;
}

.history-time {
    font-size: 0.8rem;
    color: var(--gray);
}



/* Animaciones */
@keyframes flip {
    0% { transform: rotateY(0); }
    50% { transform: rotateY(1800deg); }
    100% { transform: rotateY(3600deg); }
}

.flipping {
    animation: flip 3s cubic-bezier(0.4, 2.5, 0.6, 0.5) forwards;
}

/* Responsive */
@media (max-width: 768px) {
    h1 {
        font-size: 2.2rem;
    }

    .main-content {
        padding: 0 10px;
    }

    .coin-section, .control-panel {
        padding: 20px;
    }

    .stats {
        grid-template-columns: 1fr;
    }
}

/* Scrollbar personalizada */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}


/* ===== ARTICLE SPECIFIC STYLES - NO BODY STYLES ===== */
#coinguide-article {
      width: 95%;
      margin: 0 auto;
      padding: 2rem 1.5rem 3rem 1.5rem;
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    }

    /* Hero Section */
    .coin-guide-hero {
      text-align: center;
      margin-bottom: 2.5rem;
      padding: 2rem 1.5rem;
      background: linear-gradient(135deg, #8a5cf5 0%, #ffd166 100%);
      border-radius: 32px;
      box-shadow: 0 12px 30px rgba(138, 92, 245, 0.3);
    }

    .coin-guide-hero h2 {
      font-size: 2.6rem;
      font-weight: 800;
      color: white;
      margin-bottom: 1rem;
      letter-spacing: -0.02em;
      font-family: 'Montserrat', serif;
    }

    .coin-guide-hero .coin-hero-sub {
      font-size: 1.2rem;
      color: rgba(255, 255, 255, 0.9);
      max-width: 720px;
      margin: 0 auto;
      line-height: 1.5;
    }

    .coin-guide-meta {
      display: flex;
      justify-content: center;
      gap: 2rem;
      color: rgba(255, 255, 255, 0.8);
      font-weight: 500;
      margin-top: 1.2rem;
      flex-wrap: wrap;
    }

    .coin-guide-meta span i {
      margin-right: 0.5rem;
    }

    /* Main Content */
    .coin-main-content {
      background: white;
      border-radius: 28px;
      padding: 2rem 2rem 2.5rem 2rem;
      box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
      border: 1px solid rgba(138, 92, 245, 0.15);
    }

    .coin-main-content h2 {
      font-size: 1.8rem;
      font-weight: 700;
      margin-top: 2rem;
      margin-bottom: 1rem;
      color: #8a5cf5;
      border-left: 5px solid #ffd166;
      padding-left: 1rem;
      font-family: 'Montserrat', serif;
    }

    .coin-main-content h2:first-of-type {
      margin-top: 0;
    }

    .coin-main-content h3 {
      font-size: 1.35rem;
      font-weight: 600;
      margin: 1.5rem 0 0.75rem 0;
      color: #ffd166;
    }

    .coin-main-content p {
      font-size: 1.05rem;
      color: #2d3748;
      margin-bottom: 1.2rem;
      line-height: 1.6;
    }

    .coin-main-content ul, .coin-main-content ol {
      margin: 1rem 0 1.2rem 1.8rem;
      color: #2d3748;
      line-height: 1.6;
    }

    .coin-main-content li {
      margin-bottom: 0.5rem;
    }

    .coin-highlight-box {
      background: linear-gradient(135deg, rgba(138, 92, 245, 0.08), rgba(255, 209, 102, 0.05));
      border-left: 6px solid #ffd166;
      padding: 1.25rem 1.5rem;
      border-radius: 20px;
      margin: 1.75rem 0;
    }

    .coin-pro-tip {
      background: rgba(255, 209, 102, 0.1);
      border-radius: 20px;
      padding: 1.2rem 1.5rem;
      margin: 1.5rem 0;
      display: flex;
      gap: 1rem;
      align-items: flex-start;
      border: 1px solid rgba(138, 92, 245, 0.3);
    }

    .coin-pro-tip i {
      font-size: 1.8rem;
      color: #ffd166;
    }

    .coin-stats-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
      gap: 1.2rem;
      margin: 2rem 0;
    }

    .coin-stat-card {
      background: #f8f9fa;
      border-radius: 20px;
      padding: 1.2rem;
      text-align: center;
      transition: all 0.2s;
      border: 1px solid rgba(138, 92, 245, 0.2);
    }

    .coin-stat-card .stat-number {
      font-size: 2rem;
      font-weight: 800;
      color: #8a5cf5;
      margin-bottom: 0.25rem;
    }

    .coin-quote-block {
      background: #f8f9fa;
      padding: 1.5rem;
      border-radius: 24px;
      text-align: center;
      font-style: italic;
      margin: 1.5rem 0;
      border: 1px solid rgba(138, 92, 245, 0.2);
    }

    .coin-quote-block i {
      font-size: 2rem;
      color: #ffd166;
      margin-bottom: 0.5rem;
      display: inline-block;
    }

    .coin-table-wrapper {
      overflow-x: auto;
      margin: 1.5rem 0;
    }

    .coin-probability-table {
      width: 100%;
      border-collapse: collapse;
      background: #f8f9fa;
      border-radius: 16px;
      overflow: hidden;
    }

    .coin-probability-table th, .coin-probability-table td {
      padding: 12px 16px;
      text-align: left;
      border-bottom: 1px solid rgba(138, 92, 245, 0.2);
    }

    .coin-probability-table th {
      background: rgba(138, 92, 245, 0.1);
      font-weight: 600;
      color: #8a5cf5;
    }

    .coin-probability-table tr:hover {
      background: rgba(255, 209, 102, 0.05);
    }

    .coin-tips-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
      gap: 1.2rem;
      margin: 1.5rem 0;
    }

    .coin-tip-card {
      background: #f8f9fa;
      border-radius: 16px;
      padding: 1.2rem;
      border: 1px solid rgba(138, 92, 245, 0.2);
      transition: all 0.2s;
    }

    .coin-tip-card:hover {
      transform: translateY(-3px);
      box-shadow: 0 8px 20px rgba(138, 92, 245, 0.1);
    }

    .coin-tip-title {
      font-weight: 700;
      color: #8a5cf5;
      margin-bottom: 0.5rem;
      font-size: 1.1rem;
      display: flex;
      align-items: center;
      gap: 0.5rem;
    }

    .coin-footer-note {
      margin-top: 2.5rem;
      text-align: center;
      font-size: 0.85rem;
      color: #718096;
      border-top: 1px solid #e2e8f0;
      padding-top: 2rem;
    }

    @media (max-width: 768px) {
      .coin-guide-hero h2 {
        font-size: 2rem;
      }
      .coin-main-content {
        padding: 1.5rem;
      }
      #coinguide-article {
        padding: 1rem;
      }
    }