:root {
  --bg: #0d0d0d;
  --panel: #1a1a1a;
  --accent: #ff4d4d;
  --text: #f2f2f2;
  --radius: 8px;
  --transition: 0.2s ease;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Title */
#app-title {
  margin: 0;
  padding: 0;
  font-size: 42px;
  font-family: "Saira Stencil One", sans-serif;
  letter-spacing: 3px;
  color: white;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}

/* Controls */
#controls {
  width: 100%;
  padding: 10px 20px;
  background: var(--panel);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  border-bottom: 1px solid #333;
  flex-wrap: wrap;
}

#controls-center {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap;
}

#controls label {
  font-size: 12px;
  opacity: 0.9;
  display: flex;
  align-items: center;
  gap: 6px;
}

select, input[type="color"], input[type="range"] {
  margin-left: 0;
  font-size: 12px;
}

button {
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 8px 12px;
  border-radius: var(--radius);
  font-size: 12px;
  cursor: pointer;
  transition: var(--transition);
  font-weight: 600;
  white-space: nowrap;
}

button:hover {
  background: #ff6666;
  transform: translateY(-1px);
}

/* Canvas area */
#paint-area {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin: 20px auto;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 0 40px rgba(0,0,0,0.4);
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

#bg-img {
  width: 100%;
  display: block;
}

#canvas {
  position: absolute;
  top: 0;
  left: 0;
  touch-action: none;
  cursor: none;
}

/* Brush preview cursor */
#brush-cursor {
  position: fixed;
  pointer-events: none;
  border: 2px solid rgba(255,255,255,0.6);
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.3), 0 0 8px rgba(0,0,0,0.5);
  opacity: 0;
  transition: opacity 0.1s ease;
  transform: translate(-50%, -50%);
  z-index: 10;
}
}

/* Colour palette */
#palette {
  width: 100%;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 15px;
  margin-bottom: 0;
}

.palette-swatch {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  cursor: pointer;
  border: 2px solid #fff3;
  transition: 0.2s ease;
}

.palette-swatch:hover {
  transform: scale(1.2);
  border-color: white;
}

/* Footer */
footer {
  width: 100%;
  padding: 12px 20px;
  background: var(--panel);
  border-top: 1px solid #333;
  text-align: center;
  font-size: 11px;
  opacity: 0.7;
  margin-top: 30px;
}

footer a {
  color: var(--accent);
  text-decoration: none;
  transition: var(--transition);
}

footer a:hover {
  opacity: 1;
}

/* Partner */
#partner {
  width: 100%;
  padding: 8px 20px;
  background: #252525;
  border-top: 1px solid #333;
  border-bottom: 1px solid #333;
  text-align: center;
  font-size: 11px;
  opacity: 0.8;
  margin-top: 20px;
}

#partner a {
  color: var(--accent);
  text-decoration: none;
  transition: var(--transition);
  font-weight: 600;
}

#partner a:hover {
  opacity: 1;
}
