* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

@font-face {
  font-family: "TicketDeCaisse";
  src: url("HB-Lossy-Web-Regular-Base-v1.0.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

body {
  font-family: "TicketDeCaisse";
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 20px;
  overflow-x: hidden;
  @media (max-width: 1023px) {
    padding: 0;
  }
}

@media (max-width: 600px) {
  #mirror {
    transform: scaleX(-1);
    opacity: 6% !important;
  }
}

img {
  filter: grayscale(1);
  border: 1px #000 solid;
}

.receipt {
  width: 380px;
  background: #fff;
  color: #000;
  padding: 30px 20px;
  position: relative;
  box-shadow:
    0 0 20px rgba(255, 255, 255, 0.1),
    inset 0 0 40px rgba(0, 0, 0, 0.05);

  /* Crumpled paper effect */
  transform: rotateX(2deg) rotateY(-1deg);

  /* Slight aging effect */
  filter: contrast(1.1) brightness(0.98);

  /* Safari-compatible distortion filter */
  -webkit-filter: url("#distortion");
  filter: url("#distortion");
}

.receipt::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    radial-gradient(
      circle at 20% 30%,
      rgba(0, 0, 0, 0.02) 1px,
      transparent 1px
    ),
    radial-gradient(
      circle at 80% 70%,
      rgba(0, 0, 0, 0.02) 1px,
      transparent 1px
    ),
    radial-gradient(circle at 40% 90%, rgba(0, 0, 0, 0.01) 1px, transparent 1px);
  pointer-events: none;
}

/* Header Section */
.header-section {
  text-align: center;
  margin-bottom: 20px;
  border-bottom: 1px solid #000;
  padding-bottom: 15px;
}

.logo {
  display: flex;
  justify-content: center;
}

.logo img {
  width: 180px;
  border: none;
}

.business-name {
  font-size: 20px;
  font-weight: bold;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.business-subtitle {
  font-size: 14px;
  letter-spacing: 1px;
  color: #333;
}

/* Dividers */
.divider {
  margin: 20px 0;
  text-align: center;
}

.dashed-line {
  border-top: 2px dashed #000;
  width: 100%;
  position: relative;
}

.dashed-line::before {
  content: "✂";
  position: absolute;
  left: -5px;
  top: -9px;
  font-size: 12px;
  background: #fff;
  padding: 0 3px;
  font-variant-emoji: text;
  color: transparent;
  text-shadow: 0 0 0 #000;
  @media (max-width: 1023px) {
    transform: rotate(-90deg);
  }
}

/* Services Section */
.services-section {
  margin: 20px 0;
}

.fra-container {
  text-align: left;
  margin-bottom: 20px;
  position: relative;
  display: flex;
  font-size: 16px;
  gap: 15px;
  img {
    max-height: 150px;
  }
}

.fra-image-container {
  width: 150px;
}

p {
  margin-bottom: 20px;
}

.services-title {
  font-size: 16px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 20px;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: 2px solid #000;
  padding: 8px;
  color: #000;
}

/* Service Items */
.service-item {
  margin-bottom: 10px;
}

.service-description {
  font-size: 16px;
  line-height: 1;
  color: #000;
  text-align: left;
  font-weight: bold;
  text-transform: uppercase;
}

/* Projects Section */
.projects-section {
  margin: 20px 0;
}

.projects-title {
  font-size: 16px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 20px;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: 2px solid #000;
  padding: 8px;
  color: #000;
}

.project-item {
  margin-bottom: 15px;
}

.project-line {
  display: flex;
  align-items: center;
  margin-bottom: 5px;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  text-decoration: none;
  color: #000;
}

.project-name {
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  min-width: 0;
  flex-shrink: 0;
}

.dots {
  flex: 1;
  border-bottom: 1px dotted #000;
  margin: 0 8px;
  height: 1px;
  min-width: 20px;
}

.project-arrow {
  font-weight: bold;
  font-size: 14px;
  text-align: right;
  flex-shrink: 0;
  color: transparent;
  text-shadow: 0 0 0 #000;
}

.project-description {
  font-size: 14px;
  line-height: 1.3;
  color: #333;
}

/* Footer Section */
.footer-section {
  margin-top: 20px;
  text-align: center;
  border-top: 1px solid #000;
  padding-top: 15px;
}

.contact-info {
  margin-bottom: 15px;
}

.contact-line {
  font-size: 16px;
  margin-bottom: 3px;
}

.thank-you {
  font-size: 16px;
  font-weight: bold;
  margin: 15px 0 10px 0;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: 2px solid #000;
  padding: 5px;
  background: #f9f9f9;
}

.payment-note {
  font-size: 12px;
  color: #666;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Barcode Section */
.barcode-section {
  margin-top: 20px;
  text-align: center;
  padding-top: 15px;
}

.barcode-container {
  position: relative;
  display: inline-block;
}

.barcode-bars {
  display: flex;
  align-items: flex-end;
  gap: 1px;
  height: 40px;
  margin: 15px 0;
}

.barcode-bars .bar {
  background-color: #000;
  height: 100%;
  width: 2px;
  display: inline-block;
}

.barcode-bars .bar.wide {
  width: 4px;
}

.barcode-text {
  position: absolute;
  bottom: 12px;
  font-size: 18px;
  font-weight: bold;
  color: #000;
  padding: 0 1px;
  line-height: 1;
  width: 100%;
  left: 50%;
  transform: translateX(-50%);
  span {
    margin: 0 2px;
    background: white;
  }
}

#overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: blue;
  color: white;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  font-family: monospace;
  z-index: 9999;
}

#overlayInner {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
}

#terminal {
  white-space: pre-wrap;
  padding: 20px;
  width: 80%;
  max-width: 800px;
  text-transform: uppercase;
}

input {
  text-transform: uppercase;
  background: transparent;
  border: none;
  color: white;
  font-family: monospace;
  width: 80%;
  max-width: 800px;
  outline: none;
}
