/* Setup */

:root {
  --primary: #ffffff;
  --secondary: #fef4ea;
  --accent: #ff5c35;
  --accenthover: #e04826;
  --accentpressed: #b3361d;
  --text: #000000;
  --ff: "Roboto", sans-serif;
  --h1: bold 2.986rem var(--ff);
  --h2: bold 2.074rem/1.6 var(--ff);
  --h3: bold 1.2rem/1.6 var(--ff);
  --p: 1rem/1.6 var(--ff);
  --transition: 0.3s ease-in-out;
}

h1,
h2,
h3,
.pattyometer-main p {
  margin: 0;
}

h1 {
  font: var(--h1);
}

h2 {
  font: var(--h2);
}

h3 {
  font: var(--h3);
}

p {
  font: var(--p);
}

body {
  font-family: var(--ff);
  margin: auto;
  padding: 0;
  background-color: var(--primary);
  color: var(--text);
}

.section {
  width: 90vw;
  max-width: 1080px;
  margin: auto;
}

/* Header */

header {
  box-shadow: 0 2px 4px rgba(33, 51, 67, 0.12);
}

header .section {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-logo {
  display: flex;
  font: var(--h2);
  margin: 5px;
  gap: 10px;
  font-weight: 500;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 60px;
}

a {
  color: var(--text);
  text-decoration: none;
  font: var(--p);
}

header a:hover {
  color: var(--accent);
  transition: var(--transition);
}

.hamburger {
  display: none;
  cursor: pointer;
}

.bar {
  display: block;
  width: 25px;
  height: 3px;
  margin: 5px auto;
  transition: var(--transition);
  background-color: var(--accent);
}

@media (max-width: 800px) {
  .hamburger {
    display: block;
  }
  .hamburger.active .bar:nth-child(2) {
    opacity: 0;
  }
  .hamburger.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .hamburger.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
  .nav-menu {
    padding-top: 40px;
    background-color: var(--primary);
    position: fixed;
    right: -100%;
    top: 7%;
    align-items: flex-end;
    flex-direction: column;
    height: 100%;
    transition: var(--transition);
    margin: 0px;
  }
  .nav-menu a {
    padding: 0px 5vw;
  }
  .nav-menu.active {
    right: 0;
    width: 100%;
    transition: var(--transition);
  }
  .hero {
    flex-direction: column-reverse;
  }
  .intro {
    flex-direction: column-reverse;
  }
  .container {
    width: 90%;
  }
}

/* Hero */

.column {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.hero div {
  flex: 1;
  animation: fade-in 2s;
  -webkit-animation: fade-in 2s;
  -moz-animation: fade-in 2s;
  -o-animation: fade-in 2s;
  -ms-animation: fade-in 2s;
}

.hero img {
  width: 100%;
  margin-top: 40px;
}

.btn {
  font: var(--p);
  background: var(--accent);
  color: var(--primary);
  border: none;
  padding: 0.5em 0.75em;
  border-radius: 0.25em;
  cursor: pointer;
  transition: var(--transition);
}

.btn:hover {
  background-color: var(--accenthover);
  transition: var(--transition);
}

.btn.btn-outline {
  background: none;
  border: 1px solid var(--accent);
  color: var(--accent);
}

.btn.btn-outline:hover,
.btn.btn-outline:focus {
  background: #ffebe6;
}

.primary-links {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
}

.section-one {
  display: flex;
  min-height: 100vh;
  justify-content: center;
  align-items: center;
}

.pattyometer-header-logo,
.pattyometer-header-links {
  display: flex;
  gap: 10px;
}

.pattyometer-toggle-button {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 21px;
  cursor: pointer;
}

@media (max-width: 500px) {
  .toggle-button,
  .pattyometer-toggle-button {
    display: flex;
  }

  .header-links,
  .pattyometer-header-links {
    display: none;
    width: 100%;
    flex-direction: column;
  }

  .pattyometer-navbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .pattyometer-header-links a {
    text-align: center;
  }

  .pattyometer-header-links.active {
    display: flex;
  }
}

button {
  margin-top: 8px;
  border-radius: 8px;
  background-color: #3882f6;
  border: none;
  padding: 10px 32px;
  color: #f9faf8;
  font-weight: bold;
}

/* About Me */

#section-two {
  margin-top: 40px;
  background-color: var(--secondary);
}

#section-two .section {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 50px 0;
  gap: 16px;
}

.tag {
  opacity: 0;
  transform: translate(0, 10vh);
  transition: all 2s;
}

.tag.visible {
  opacity: 1;
  transform: translate(0, 0);
}

/* Projects */

.section-three {
  padding: 50px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1rem;
  align-items: flex-start;
  margin-top: 16px;
}

.card {
  --padding: 1rem;
  background-color: white;
  box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.2);
  border-radius: 0.25rem;
  overflow: hidden;
  transition: 200ms transform ease-in-out;
}

.card:hover {
  transform: scale(1.025);
}

.card-header {
  font: var(--h3);
  padding: var(--padding);
  padding-bottom: 0;
  margin-bottom: 0.5rem;
}

.card-header.card-img {
  padding: 0;
  overflow: hidden;
}

.card-header.card-img > img {
  display: block;
  width: 100%;
  max-height: 200px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center;
  transition: 200ms transform ease-in-out;
}

.card:hover > .card-header.card-img > img {
  transform: scale(1.025);
}

.card-body {
  font: var(--p);
  padding: 0 var(--padding);
}

.card-footer {
  padding: var(--padding);
  padding-top: 0;
}

.card-btn {
  font: var(--p);
  background: var(--accent);
  color: var(--primary);
  border: none;
  padding: 0.5em 0.75em;
  border-radius: 0.25em;
  cursor: pointer;
  transition: var(--transition);
}

.card-btn a {
  color: var(--primary);
}

.card-btn:hover,
.card-btn:focus {
  background: var(--accenthover);
}

/* Connect With Me  */

footer {
  background-color: var(--secondary);
}

footer .section {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 50px 0;
  gap: 16px;
}

.icons {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icons a img:hover {
  transform: scale(1.2);
  transition: var(--transition);
}

.copyright,
.copyright a {
  color: #f9c48b;
}

/* Donut Calculator */

.intro {
  padding: 50px 0;
}

.intro div {
  flex: 1;
  flex-wrap: wrap;
}

.intro img {
  width: 100%;
}

.parkrun-text {
  display: flex;
  justify-content: center;
}

.parkrun-section-two {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 50px;
  background-color: var(--secondary);
  padding: 100px 0px;
}

.section-two-content {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

.calculator-txt {
  width: min(90%, 400px);
  font-size: 16px;
  line-height: 25px;
}

.form {
  width: min(90%, 400px);
}

#donut-form {
  display: flex;
  justify-content: center;
  align-items: center;
}

fieldset {
  border-radius: 8px;
}

.form-row {
  margin: 15px;
  display: flex;
  justify-content: center;
  flex-direction: column;
  flex-wrap: wrap;
}

.form-row label {
  margin-bottom: 10px;
}

.form-row input {
  border: 1px solid #d6d9dc;
  border-radius: 3px;
  width: 50%;
  padding: 5px;
  font-size: 14px;
}

.form-row select {
  border: 1px solid #d6d9dc;
  border-radius: 3px;
  width: 50%;
  padding: 5px;
  font-size: 14px;
}

button:hover,
button:focus {
  background: #0053ba;
}

button:focus {
  outline: 1px solid #fff;
  outline-offset: -4px;
}

button:active {
  transform: scale(0.99);
}

.form-row .btn {
  width: 50%;
  cursor: pointer;
}

#total {
  margin: 10px;
}

/* Bus Tracker */

.background {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-image: url(../images/bus-background.png);
  background-position: center center;
  background-size: cover;
  background-position: center;
}

.grid-container {
  display: grid;
  grid-template: 40px 40px 40px 40px 40px 40px 40px 40px 40px / 130px 240px;
  height: 100vh;
  justify-content: center;
  align-content: center;
  column-gap: 20px;
  color: white;
  margin-bottom: 40px;
}

.thornbury,
.a38,
.bradley-stoke,
.m32,
.bristol,
.buses,
.arrow-down,
.arrow-up {
  justify-self: center;
}

.text-link {
  text-decoration: underline;
  color: yellow;
  padding-top: 50px;
}

.bus-section-two {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: #f7d060;
  padding: 50px 0px;
}

.bus-text {
  width: min(90%, 820px);
  line-height: 25px;
}

.client-server-img {
  width: 100%;
}

/* Pipsqueak */

.pattyometer-navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #ffc000;
}

.pattyometer-header-logo {
  font-size: 24px;
  font-weight: 900;
  color: #f9faf8;
  margin: 0.5rem;
}

.pattyometer-header-logo a {
  text-decoration: none;
  color: black;
}

.pattyometer-header-links a {
  text-decoration: none;
  color: black;
  margin: 0 10px;
  font-size: 18px;
}

.pattyometer-toggle-button .bar {
  height: 3px;
  width: 100%;
  background-color: black;
  border-radius: 10px;
}

.pattyometer-section-one {
  display: flex;
  flex-direction: column;
  background-color: #ffc000;
  justify-content: center;
  align-items: center;
  padding-top: 50px;
}

.pattyometer-title {
  text-align: center;
  width: 80%;
}

.container {
  max-width: 1028px;
}

.why-pattyometer {
  width: min(90%, 600px);
  font-size: clamp(1rem, 16px, 2rem);
  line-height: 25px;
}

.how-pattyometer-works {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: min(90%, 600px);
  line-height: 25px;
}

.conceptual-model-img {
  margin-top: 40px;
  margin-bottom: 40px;
  width: 90%;
}

.wireframes {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.wireframe,
.design {
  width: 40%;
}

.full-designs {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
  gap: 10px;
}

.design {
  border: 1px solid black;
}

.mobile {
  width: 13%;
  border: 1px solid black;
}

/* Patty-O-Meter */

.pattyometer-main {
  display: flex;
  flex-direction: column;
  background-color: #ffc000;
  align-items: center;
  font-family: "Bebas Neue", sans-serif;
  font-size: 1.5rem;
  padding-top: 50px;
}

.pattyometer-main p {
  font-size: 1.5rem;
  font-family: "Bebas Neue", sans-serif;
}

.pattyometer-main a {
  text-decoration: underline;
}

.test-site {
  text-align: center;
  width: 90%;
}

.squeezed-logo-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 50%;
  margin-top: 40px;
}

.squeezed-logo {
  width: min(80%, 250px);
}

.logo-text-container {
  position: absolute;
  margin-top: 170px;
}

.logo-text {
  margin: 0;
  padding: 0;
  font-size: 1.2rem;
}

.pattyometer-gauge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 50px;
  width: min(90%, 400px);
  /* border: 1px solid black; */
}

.gauge-needle {
  display: flex;
  align-items: center;
  justify-content: center;
  /* border: 1px solid black; */
}

.gauge {
  width: 95%;
  /* border: 1px solid black; */
}

.labels {
  display: flex;
  width: 100%;
}

.sold-out {
  margin: 0;
  width: 100%;
}

.patties-galore {
  margin: 0;
  width: 47%;
  text-align: right;
}

.needle {
  position: absolute;
  margin-top: 147px;
  transform: rotate(90deg);
  width: min(40%, 140px);
}

.under-pattyometer {
  display: flex;
  flex-direction: row;
  gap: 5px;
  margin-top: 10px;
  font-size: 20px;
  z-index: 1;
}

.refresh-container {
  display: flex;
  align-items: center;
}

.refresh {
  margin: 0;
  font-size: 20px;
}

.squeezed-burger {
  animation: pulse 1.5s infinite;
  cursor: pointer;
  margin-left: 20px;
}

.hours-table-container {
  margin-top: 40px;
  margin-bottom: 30px;
  width: 300px;
  font-size: 20px;
}

@keyframes shake {
  0% {
    transform: translate(1px, 1px) rotate(0deg);
  }
  10% {
    transform: translate(-1px, -2px) rotate(-1deg);
  }
  20% {
    transform: translate(-3px, 0px) rotate(1deg);
  }
  30% {
    transform: translate(3px, 2px) rotate(0deg);
  }
  40% {
    transform: translate(1px, -1px) rotate(1deg);
  }
  50% {
    transform: translate(-1px, 2px) rotate(-1deg);
  }
  60% {
    transform: translate(-3px, 1px) rotate(0deg);
  }
  70% {
    transform: translate(3px, 1px) rotate(-1deg);
  }
  80% {
    transform: translate(-1px, -1px) rotate(1deg);
  }
  90% {
    transform: translate(1px, 2px) rotate(0deg);
  }
  100% {
    transform: translate(1px, -2px) rotate(-1deg);
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes up-down {
  0% {
    transform: translateY(10px);
  }
  100% {
    transform: translateY(-10px);
  }
}

@keyframes fade-in {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

#table-container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  background-color: #ffc000;
  font-family: "Bebas Neue", sans-serif;
  font-size: 1.4rem;
}

table {
  border: 1px solid black;
  border-collapse: collapse;
  width: 100%;
}

tr,
td {
  border: 1px solid black;
  padding: 10px;
}
