/* ===== 首頁專用樣式 (homepage.css) ===== */
/* 用於取代 index.html 中重複的 inline style，集中管理首頁專屬的視覺樣式 */

/* 通用工具類 */
.mb-2rem {
    margin-bottom: 2rem;
}

.text-link-underline {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 2rem;
    color: var(--color-brand);
    font-weight: var(--font-semibold);
    text-decoration: none;
}

.text-link-underline:hover {
    text-decoration: underline;
}

/* 漸層圖示圓圈 (用於「甚麼是STEM獎勵計劃」及「計劃內容」任務卡) */
.icon-circle {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #9333ea 0%, #ec4899 50%, #f97316 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.icon-circle img {
    height: 40px;
    width: 40px;
}

.icon-circle-wrap {
    text-align: left;
    margin-bottom: 20px;
}

/* 快捷功能卡片 */
.quick-link-card {
    align-items: center;
    padding: 15px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 15px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid #e2e8f0;
}

.quick-link-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-color: #9333ea;
}

.quick-link-card.disabled {
    position: relative;
    background: linear-gradient(135deg, #9ca3af 0%, #6b7280 100%);
    opacity: 0.7;
    cursor: not-allowed;
}

.quick-link-card.highlight {
    background: linear-gradient(135deg, #9333ea 0%, #ec4899 50%, #f97316 100%);
}

.quick-link-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #9333ea 0%, #ec4899 50%, #f97316 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px auto;
    flex-shrink: 0;
}

.quick-link-icon.icon-plain {
    background: #F3F7FA;
}

.quick-link-label {
    color: #1e293b;
    text-align: center;
}

.quick-link-label.text-white {
    color: white;
}

.quick-link-badge {
    display: none;
    position: absolute;
    top: -8px;
    right: -8px;
    background: #dc2626;
    color: white;
    padding: 4px 12px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* 甚麼是STEM獎勵計劃 - 特色欄位 */
.program-feature-row {
    display: flex;
    justify-content: flex-start;
    gap: 2rem;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.program-feature-col {
    text-align: left;
    flex: 1;
    min-width: 200px;
}

.program-feature-col h4 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #1e293b;
}

.program-feature-col p {
    color: #64748b;
}

/* 參加資格 - 條件列表 */
.qualification-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 20px;
}

.qualification-item.warning {
    background: #fef3c7;
    border: 1px solid #fbbf24;
    border-radius: 12px;
    padding: 15px 20px;
}

.qualification-item.warning .warning-icon {
    font-size: 1.2rem;
    line-height: 1;
}

.qualification-item.warning p {
    margin: 0;
    color: #92400e;
    font-weight: 600;
}

.qualification-cta-row {
    margin-top: 2rem;
    display: flex;
    gap: 1rem;
    justify-content: flex-start;
    flex-wrap: wrap;
    align-items: center;
}

/* 自選比賽 - 品牌 Logo 容器 (高度依原始 Logo 比例個別設定，保留 inline style) */
.competition-logo-box {
    text-align: left;
    margin-bottom: 20px;
    height: 70px;
    display: flex;
    align-items: center;
}

/* CTA 區域 */
.cta-gradient-section {
    background: linear-gradient(135deg, #9333ea 0%, #ec4899 50%, #f97316 100%);
    color: white;
}

.cta-gradient-section .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.cta-animated-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 2rem;
    animation: ctaColorChange 2s infinite alternate;
}

@keyframes ctaColorChange {
    0% { color: white; }
    100% { color: #F4B847; }
}

/* 贊助商區塊 */
.sponsor-logo-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.sponsor-advisor-card {
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 8px;
    width: 100%;
    max-width: 200px;
}

.sponsor-advisor-name {
    font-size: 0.875rem;
    color: #6b7280;
    text-align: center;
}

/* 獎章及獎狀派發安排 Popup */
.award-popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.award-popup-box {
    background: white;
    border-radius: 16px;
    max-width: 420px;
    width: 90%;
    padding: 0;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
    position: relative;
    animation: popupFadeIn 0.3s ease;
}

.award-popup-header {
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
}

.award-popup-header-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.award-popup-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.award-popup-title {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
}

.award-popup-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
}

.award-popup-close:hover {
    background: #f1f5f9;
}

.award-popup-body {
    padding: 24px;
}

.award-popup-notice {
    padding: 20px;
    border-radius: 12px;
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border: 1px solid #fcd34d;
}

.award-popup-notice p {
    margin: 0;
    color: #92400e;
    font-weight: 500;
    text-align: center;
    font-size: 1rem;
    line-height: 1.6;
}

.award-popup-subtext {
    margin: 16px 0 0 0;
    color: #64748b;
    text-align: center;
    font-size: 0.875rem;
}

.award-popup-footer {
    padding: 16px 24px;
    border-top: 1px solid #e2e8f0;
    text-align: center;
}

.award-popup-confirm-btn {
    padding: 10px 32px;
    background: linear-gradient(135deg, #9333ea 0%, #7c3aed 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.award-popup-confirm-btn:hover {
    transform: scale(1.02);
}

@keyframes popupFadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}
