/* ============================================
   多语言免费临时邮箱网站 — 主样式表
   设计风格：国际简约 · 浅色柔和 · 响应式
   ============================================ */

/* ---- 基础重置 ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans SC', sans-serif;
  background: #f5f7fa;
  color: #2c3e50;
  line-height: 1.6;
  min-height: 100vh;
}

/* ---- 容器 ---- */
.container {
  max-width: 820px;
  margin: 0 auto;
  padding: 20px 16px 40px;
}

/* ============================================
   模块1：顶部区域
   ============================================ */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0 16px;
  flex-wrap: wrap;
  gap: 10px;
}
.header-title {
  font-size: 22px;
  font-weight: 700;
  color: #1a73e8;
  letter-spacing: -0.3px;
}
.lang-selector select {
  padding: 6px 28px 6px 12px;
  border: 1px solid #d0d5dd;
  border-radius: 8px;
  font-size: 14px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") no-repeat right 10px center;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  color: #333;
  min-width: 140px;
  transition: border-color 0.2s;
}
.lang-selector select:focus { border-color: #1a73e8; outline: none; box-shadow: 0 0 0 2px rgba(26,115,232,0.15); }

/* ============================================
   广告位
   ============================================ */
.ad-slot {
  background: #f0f2f5;
  border: 1px dashed #d0d5dd;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  font-size: 12px;
}
.ad-top { width: 100%; height: 90px; margin-bottom: 24px; }
.ad-bottom { width: 100%; max-width: 480px; height: 120px; margin: 28px auto; }

/* ============================================
   模块3：核心功能区
   ============================================ */
.main-section {
  background: #fff;
  border-radius: 12px;
  padding: 32px 24px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  margin-bottom: 20px;
}
.email-input {
  width: 100%;
  padding: 14px 18px;
  font-size: 17px;
  font-family: 'SF Mono', 'Consolas', 'Liberation Mono', monospace;
  border: 2px solid #e0e4e8;
  border-radius: 10px;
  background: #f8f9fb;
  color: #1a73e8;
  text-align: center;
  cursor: default;
  outline: none;
  transition: border-color 0.2s;
  letter-spacing: 0.5px;
}
.email-input:focus { border-color: #1a73e8; box-shadow: 0 0 0 3px rgba(26,115,232,0.1); }

.btn-group {
  display: flex;
  gap: 10px;
  margin-top: 18px;
  flex-wrap: wrap;
  justify-content: center;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 100px;
  user-select: none;
  -webkit-user-select: none;
}
.btn:active { transform: scale(0.96); }
.btn-primary {
  background: #1a73e8;
  color: #fff;
}
.btn-primary:hover { background: #1557b0; }
.btn-secondary {
  background: #f0f2f5;
  color: #333;
}
.btn-secondary:hover { background: #e0e4e8; }

.countdown-row {
  text-align: center;
  margin-top: 16px;
  font-size: 14px;
  color: #666;
}
.countdown-time {
  font-weight: 700;
  font-size: 18px;
  color: #e74c3c;
  font-variant-numeric: tabular-nums;
  letter-spacing: 1px;
}

/* ============================================
   模块4：收件展示区
   ============================================ */
.inbox-section {
  background: #fff;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
  min-height: 160px;
}
.inbox-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
  color: #333;
}
.inbox-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.inbox-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.inbox-table th {
  background: #f8f9fb;
  padding: 10px 12px;
  text-align: left;
  font-weight: 600;
  color: #555;
  border-bottom: 2px solid #e0e4e8;
  white-space: nowrap;
}
.inbox-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #edf0f4;
  vertical-align: top;
  word-break: break-word;
}
.col-sender { width: 22%; }
.col-subject { width: 28%; }
.col-content { width: 50%; }
.mail-row:hover td { background: #f8f9fb; }
.mail-sender { font-weight: 500; color: #333; }
.mail-subject { color: #555; }
.mail-content { color: #666; font-size: 13px; line-height: 1.5; max-height: 60px; overflow-y: auto; }

.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: #999;
  font-size: 14px;
}

/* ============================================
   模块6：底部信息区
   ============================================ */
.footer {
  text-align: center;
  padding-top: 28px;
}
.footer-text {
  font-size: 13px;
  color: #888;
  margin-bottom: 6px;
  line-height: 1.5;
}
.footer-links {
  margin: 10px 0 6px;
}
.footer-link {
  font-size: 13px;
  color: #1a73e8;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-link:hover {
  color: #1557b0;
  text-decoration: underline;
}
.footer-link-sep {
  margin: 0 8px;
  color: #ccc;
}
.footer-copy {
  font-size: 12px;
  color: #aaa;
  margin-top: 10px;
}

/* ============================================
   轻提示
   ============================================ */
.toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-80px);
  background: #333;
  color: #fff;
  padding: 10px 24px;
  border-radius: 8px;
  font-size: 14px;
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 9999;
  pointer-events: none;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ============================================
   响应式适配
   ============================================ */
@media (max-width: 600px) {
  .container { padding: 12px 10px 30px; }
  .header-title { font-size: 18px; }
  .lang-selector select { min-width: 120px; font-size: 13px; }
  .main-section { padding: 20px 14px; }
  .email-input { font-size: 14px; padding: 12px 14px; }
  .btn { padding: 9px 14px; font-size: 13px; min-width: 70px; }
  .btn-group { gap: 6px; }
  .inbox-section { padding: 16px 12px; }
  .inbox-table { font-size: 13px; }
  .inbox-table th, .inbox-table td { padding: 8px 8px; }
  .col-sender, .col-subject, .col-content { width: auto; }
  .ad-top { height: 70px; }
  .ad-bottom { height: 90px; }
  .footer-text { font-size: 12px; }
}

@media (max-width: 400px) {
  .header { flex-direction: column; align-items: flex-start; }
  .btn { flex: 1; min-width: 60px; padding: 8px 10px; font-size: 12px; }
}

/* 印地语字体适配 */
:lang(hi) { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Noto Sans Devanagari', 'Nirmala UI', sans-serif; }
