:root {
  --primary: #8b0000;
  /* Blood Red */
  --primary-bright: #ff0000;
  --bg-dark: #050505;
  --bg-card: rgba(10, 10, 10, 0.9);
  --text-main: #d1d1d1;
  --text-muted: #666666;
  --border: rgba(139, 0, 0, 0.3);
  --glitch-speed: 0.2s;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Courier New', 'Noto Sans TC', monospace;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.8;
  overflow-x: hidden;
  background-image: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0.8) 100%),
    url('https://www.transparenttextures.com/patterns/asfalt-dark.png');
}

.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Flicker Animation */
@keyframes flicker {

  0%,
  19.999%,
  22%,
  62.999%,
  64%,
  64.999%,
  70%,
  100% {
    opacity: 1;
    text-shadow: 0 0 8px var(--primary);
  }

  20%,
  21.999%,
  63%,
  63.999%,
  65%,
  69.999% {
    opacity: 0.4;
    text-shadow: none;
  }
}

@keyframes glitch {
  0% {
    transform: translate(0);
    text-shadow: -2px 0 red, 2px 0 blue;
  }

  25% {
    transform: translate(-2px, 2px);
  }

  50% {
    transform: translate(2px, -2px);
    text-shadow: 2px 0 red, -2px 0 blue;
  }

  75% {
    transform: translate(-2px, -2px);
  }

  100% {
    transform: translate(0);
  }
}

.flicker {
  animation: flicker 3s infinite;
}

.glitch:hover {
  animation: glitch var(--glitch-speed) infinite linear alternate-reverse;
}

/* Glassmorphism V2 - Gritty */
.glass {
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  box-shadow: 0 0 20px rgba(139, 0, 0, 0.1);
}

.gradient-text {
  background: linear-gradient(180deg, #ffffff 0%, var(--primary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-transform: uppercase;
  letter-spacing: 0.2em;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.hero h1 {
  font-size: 5rem;
  margin-bottom: 1rem;
}

.hero p {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 2rem;
  letter-spacing: 0.1em;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.8rem 2.5rem;
  border: 1px solid var(--primary);
  background: transparent;
  color: var(--primary-bright);
  text-decoration: none;
  font-weight: 700;
  text-transform: uppercase;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.btn:hover {
  background: var(--primary);
  color: white;
  box-shadow: 0 0 15px var(--primary);
}

/* Section Styling */
section {
  padding: 8rem 0;
  border-bottom: 1px solid rgba(139, 0, 0, 0.1);
}

.section-title h2 {
  font-size: 3rem;
  color: var(--primary);
  text-transform: uppercase;
  margin-bottom: 2rem;
  text-align: center;
}

.card {
  padding: 3rem 2.5rem;
  margin-bottom: 2rem;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--primary);
}

.grid {
  display: grid;
  gap: 3rem;
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

#contact a {
  color: var(--primary-bright);
  text-decoration: none;
}

#contact a:hover {
  text-decoration: underline;
}

.footer {
  padding: 5rem 0;
  text-align: center;
  font-size: 0.8rem;
  color: #333;
  letter-spacing: 0.3em;
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 3rem;
  }
}

/* Billing Form Specific */
.billing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.form-group-title {
  grid-column: 1 / -1;
  color: var(--primary);
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.5rem;
  margin-top: 1rem;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.1em;
}

.input-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.input-item label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

.input-item input,
.input-item select {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  padding: 0.8rem;
  color: var(--text-main);
  font-family: inherit;
  transition: all 0.3s ease;
}

.input-item input:focus,
.input-item select:focus {
  outline: none;
  border-color: var(--primary-bright);
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.2);
  background: rgba(139, 0, 0, 0.05);
}

#billingTable tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.3s ease;
}

#billingTable tr:hover {
  background: rgba(139, 0, 0, 0.05);
}

@media (max-width: 600px) {
  .billing-grid {
    grid-template-columns: 1fr;
  }
}