/* 這裡是 CSS 樣式區塊 */
/* CSS 保持不變 */
body {
    font-family: 'Inter', 'Noto Sans TC', sans-serif;
    background-color: #F8F8F8;
    color: #333;
}

h1,
h2 {
    color: #333;
}

.card-scene {
    perspective: 1000px;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.card-inner.is-flipped {
    transform: rotateY(180deg);
}

.card-front,
.card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 0.35rem;
    /* 卡片的圓角 (您修改的) */
    overflow: hidden;
    /* 簡易防護: 禁止選取與禁止滑鼠右鍵選單 */
    user-select: none;
    -webkit-user-select: none;
    pointer-events: auto;
}

.card-front {
    transform: rotateY(180deg);
}

.card-back {
    background: url('len-img/len-back.png') no-repeat center center;
    background-size: cover;
}

/* 全局卡片長寬比 */
#cardDisplay .card-scene {
    aspect-ratio: 284 / 426;
}

/* 按鈕樣式 */
.btn-draw,
.btn-reset {
    background-color: #BD5FFF;
    color: white;
    border-radius: 0.75rem;
    /* 按鈕圓角 */
    font-weight: 600;
    transition: all 0.2s ease-in-out;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    line-height: 1.5rem;
}

.btn-draw:hover {
    background-color: #a44ee2;
}

.btn-draw:disabled {
    background-color: #d1d5db;
    cursor: not-allowed;
    color: #6b7280;
}

.btn-reset {
    background-color: #ef4444;
}

.btn-reset:hover {
    background-color: #dc2626;
}

/* 【新增】重抽按鈕在禁用時的樣式 */
.btn-reset:disabled {
    background-color: #d1d5db;
    cursor: not-allowed;
    color: #6b7280;
}

/* 佔位符樣式 */
.card-placeholder {
    visibility: hidden;
    aspect-ratio: 284 / 416;
}

/* 洗牌中動畫 (Shuffling Animation) */
@keyframes draw-pulse {
    0%, 100% { opacity: 0.6; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1.05); }
}
.animate-draw-pulse {
    animation: draw-pulse 1.2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}