/* public/style.css */

@import 'variables.css';
@import 'timegrid.css';
@import 'forms.css';
@import 'grid.css';

/* --- RESET --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* --- BASE STYLES --- */
body {
  background-color: var(--bg);
  color: var(--fg);
  font-family: 'Sofia Sans', sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  font-size: var(--text-base);
  line-height: 1.5;
  margin: 0 auto;

  /* font-family: 'Anaheim', sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal; */

  /* Center the layout visually on large screens */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Route-specific color system - override --bg and --accent variables */
body[data-route='projects'] {
  --bg: var(--project-color);
  --accent: var(--project-color);
}

body[data-route='goals'] {
  --bg: var(--goal-color);
  --accent: var(--goal-color);
}

body[data-route='actions'] {
  --bg: var(--action-color);
  --accent: var(--action-color);
}

/* --- TYPOGRAPHY --- */
h1,
h2,
h3 {
  font-weight: 800; /* Extra Bold */
  letter-spacing: -0.04em; /* Tight tracking for brutalist feel */
  line-height: 1.1;
  margin-bottom: var(--spacer);
  text-transform: uppercase; /* Optional: adds to brutalist vibe */
}

h1 {
  font-size: var(--text-h1);
  border-bottom: 4px solid var(--fg);
  padding-bottom: 10px;
}
h2 {
  font-size: var(--text-h2);
  margin-top: calc(var(--spacer) * 2);
}
h3 {
  font-size: var(--text-h3);
}
/* Readable line length */

/* --- COMPONENT: CARD / SECTION --- */
/* Brutalist Touch: Visible borders everywhere */
.box {
  border: 2px solid var(--border);
  padding: var(--spacer);

  /* Placeholders for grid positioning (default to full width) */
  grid-column: span 12;
}

/* --- COMPONENT: BUTTONS --- */
button {
  background: var(--fg);
  color: var(--bg);
  border: 2px solid var(--fg);
  padding: 12px 24px;
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all 0.2s;

  /* Hard shadow for brutalist depth */
  box-shadow: 4px 4px 0px 0px var(--accent);
}

button:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0px 0px var(--accent);
}

button:active {
  transform: translate(2px, 2px);
  box-shadow: 0px 0px 0px 0px var(--accent);
}

/* --- UTILITIES FOR COLUMNS --- */
/* You use these classes in your HTML to size elements */
.col-12 {
  grid-column: span 12;
}
.col-8 {
  grid-column: span 8;
}
.col-6 {
  grid-column: span 6;
}
.col-4 {
  grid-column: span 4;
}
ul {
  list-style-type: none;
  padding-left: 0;
}
li {
  margin-bottom: 10px;
}
.link-button {
  background: none;
  border: none;
  color: var(--accent);
  text-decoration: none;
  cursor: pointer;
  font-size: var(--text-sm);
  padding: 0;
  font-size: 2rem;
  width: 5rem;
  display: inline-block;
  span {
    font-size: 1rem;
    color: transparent;
  }
}
a {
  text-decoration: none;
  color: var(--opacity-50);
}
a:hover {
  text-decoration: underline;
}
a:visited {
  color: var(--opacity-50);
}

form {
  width: 100%;
  label {
    display: block;
    margin-bottom: var(--spacer-xs);
    font-weight: 700;
    text-transform: uppercase;
    font-size: var(--text-sm);
  }
  .form-group {
    margin-bottom: var(--spacer);
  }
}
/* --- COMPONENT: FORMS --- */
input,
textarea,
select {
  width: 100%;
  background: transparent;
  border: none;
  border: 2px solid var(--border); /* Underline only */
  padding: var(--spacer);
  font-size: var(--text-base);
  font-family: inherit;
  color: var(--fg);
  border-radius: 0; /* NO ROUNDED CORNERS */
}

input[type='text']:focus {
  outline: none;
  background: var(--bg);
}
textarea:focus {
  outline: none;
  background: var(--bg);
}
select:focus {
  outline: none;
  background: var(--bg);
}

pre {
  color: #fafafa;
  padding: var(--spacer);
  overflow-x: auto;
  font-size: var(--text-sm);
}

header {
  width: 100%;
  height: 500px;
  margin-top: -500px;
  grid-column: span 12;
  display: grid;
  grid-template-columns: repeat(var(--grid-cols), 1fr);
  gap: var(--gutter);
  justify-items: center;
  align-items: center;
  text-align: center;
  justify-content: space-between;
  align-items: center;
  z-index: 999;
  transition: margin-top 0.3s ease;
  color: var(--fg);
  &.open {
    height: auto;
    margin-top: 0;
  }
}

footer {
  width: 100%;
  font-size: var(--text-sm);
  color: var(--opacity-50);
  z-index: 100;
}
article {
  margin-bottom: var(--spacer-xl);
}

.burger-menu {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  font-size: 2rem;
  padding: 10px 15px;

  border: 2px solid var(--fg);
  cursor: pointer;
}

.burger-menu:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0px 0px var(--accent);
}

.burger-menu:active {
  transform: translate(2px, 2px);
  box-shadow: 0px 0px 0px 0px var(--accent);
}

.color-pickers {
  display: flex;
  gap: var(--spacer);
  flex-wrap: wrap;
}

.color-picker-group {
  display: flex;
  flex-direction: column;
  gap: var(--spacer-xs);
}

.color-picker-group label {
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  margin: 0;
}

.color-picker-group input[type='color'] {
  width: 60px;
  height: 40px;
  border: 2px solid var(--border);
  cursor: pointer;
  padding: 2px;
  background: transparent;
}

.color-picker-group input[type='color']::-webkit-color-swatch-wrapper {
  padding: 0;
}

.color-picker-group input[type='color']::-webkit-color-swatch {
  border: none;
}

.list-item {
  border-left: 1px solid var(--border);
  padding-left: var(--spacer-sm);
}

.list-item.completed {
  text-decoration: line-through;
  color: var(--opacity-50);
}

/* --- MEDIA QUERIES FOR RESPONSIVENESS --- */
@media (max-width: 1024px) {
  body {
    padding: 20px;
  }
}
/* Responsive: Collapse to 1 column on mobile */
@media (max-width: 768px) {
  .grid {
    display: flex;
    flex-direction: column;
  }
  .box,
  .col-8,
  .col-6,
  .col-4 {
    width: 100%;
  }
}
