@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;900&display=swap');

@tailwind base;
@tailwind components;
@tailwind utilities;

/* CSS Reset start */

/* Box sizing rules */
*,
*::before,
*::after {
  box-sizing: border-box;
  /* font-size: 62.5%; Now 10px = 1rem! */
}

/* Remove default margin */
body,
h1,
h2,
h3,
h4,
p,
ul[class],
ol[class],
li,
figure,
figcaption,
blockquote,
dl,
dd {
  margin: 0;
}

/* Set core body defaults */
body {
  scroll-behavior: smooth;
  text-rendering: optimizeSpeed;
  line-height: 1.5;
  font-family: Poppins, Arial, sans-serif;
  cursor: none;
}

/* A elements that don't have a class get default styles */
a:not([class]) {
  text-decoration-skip-ink: auto;
}

/* Make images easier to work with */
img {
  max-width: 100%;
  display: block;
}

/* Natural flow and rhythm in articles by default */
article > * + * {
  margin-top: 1em;
}

/* Inherit fonts for inputs and buttons */
input,
button,
textarea,
select {
  font: inherit;
}
/* Add this class to hide element from document, but show them to screen-readers */
.visually-hidden:not(:focus):not(:active) {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

/* Blinking outline indicator */

.blink {
  border: 4px #ff0000 solid;

  animation: blink 3s infinite;
}

@keyframes blink {
  50% {
    border-color: #fff;
  }
}

/* CSS Reset end */

/* FONTS */

@font-face {
  font-family: 'Rage Italic';
  font-style: normal;
  font-weight: normal;
  src: local('Rage Italic'),
    url('./ressources/fonts/RAGE_1.woff') format('woff');
}

@font-face {
  font-family: 'Corbel';
  src: url('https://fonts.cdnfonts.com/css/corbel?styles=65647,65649,65650,65651,65648,65652');
}

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@200&display=swap');

@import url('https://fonts.cdnfonts.com/css/kozuka-gothic-pr6n');

/* GLOBAL STYLE  */

/* CTA BTN */
.btn {
  background: #c65a48;
  border: none;
  height: 2.9rem;
  width: 11rem;
  border-radius: 50px;
  padding: 0;
  position: relative;
}

.btn::before {
  content: '';
  position: absolute;
  width: 13rem;
  height: 1.5px;
  background: #333132;
  left: -1rem;
  transform: scaleX(0.15);
  transform-origin: right;
  transition: transform 0.2s ease-in-out;
}

.btn:hover::before {
  transform: scaleX(1);
}

.btn > span {
  display: block;
  line-height: 0.8;
  color: white;
  font-size: 21px;
  font-family: Corbel, sans-serif;
  height: 1.9999rem;
  width: 11rem;
  display: flex;
  justify-content: center;
  align-items: center;
  position: absolute;
  left: 0rem;
  transition: transform 0.3s ease;
}

.btn__top {
  clip-path: polygon(0 0, 100% 0, 100% 50%, 0 50%);
  top: 0.4rem;
}

.btn:hover .btn__top {
  transform: translateY(-6px);
}

.btn__bot {
  clip-path: polygon(0 50%, 100% 50%, 100% 100%, 0 100%);
  bottom: 0.5rem;
}

.btn:hover .btn__bot {
  transform: translateY(6px);
}

/* CUSTOM CURSOR */

#cursor {
  z-index: 99;
  position: fixed;
  pointer-events: none;
  will-change: transform;
}

.cursor--inner.hovered {
  width: 70px !important;
  height: 70px !important;
  color: #333132 !important;
  background: conic-gradient(
        from 165deg at top,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      top,
    conic-gradient(
        from 75deg at left,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      left,
    conic-gradient(
        from -15deg at bottom,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      bottom,
    conic-gradient(
        from -105deg at right,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      right;
  background-size: 100% 50%, 50% 100%;
  -webkit-mask: radial-gradient(circle 5px, #0000 90%, #333132);
  background-repeat: no-repeat;
  animation: sh1 1.9s infinite linear !important;
  position: absolute;
  top: -33px !important;
  left: -33px !important;
  transition: width 0.2s ease-in-out, height 0.2s ease-in-out, color 0.2s ease;
}

.cursorExpand {
  width: 40px !important;
  height: 40px !important;
  top: -19px !important;
  left: -19px !important;
  transition: all 0.2s ease-in-out;
  animation: grow 0.2s ease-in-out;
  background: radial-gradient(
        150% 150% at left -40% top -40%,
        #0000 98%,
        currentColor
      )
      left top,
    radial-gradient(150% 150% at right -40% top -40%, #0000 98%, currentColor)
      right top,
    radial-gradient(150% 150% at left -40% bottom -40%, #0000 98%, currentColor)
      left bottom,
    radial-gradient(
        150% 150% at right -40% bottom -40%,
        #0000 98%,
        currentColor
      )
      right bottom !important;
  background-size: 50.3% 50.3% !important;
  background-repeat: no-repeat !important;
  -webkit-mask: radial-gradient(circle 5px, #0000 90%, #000) !important;
}

#cursor .cursor--inner {
  width: 50px;
  height: 50px;
  color: #c65a48;
  background: conic-gradient(
        from 165deg at top,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      top,
    conic-gradient(
        from 75deg at left,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      left,
    conic-gradient(
        from -15deg at bottom,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      bottom,
    conic-gradient(
        from -105deg at right,
        #0000,
        currentColor 1deg 30deg,
        #0000 31deg
      )
      right;
  background-size: 100% 50%, 50% 100%;
  -webkit-mask: radial-gradient(circle 5px, #0000 90%, #000);
  background-repeat: no-repeat;
  animation: sh1 3.5s infinite linear;
  position: absolute;
  top: -23px;
  left: -24px;
  transition: width 0.2s ease-in-out, height 0.2s ease-in-out, color 0.2s ease;
}

@keyframes grow {
  from {
    width: 50px;
    height: 50px;
  }
  to {
    width: 70px !important;
    height: 70px !important;
  }
}

@keyframes sh1 {
  100% {
    transform: rotate(1turn);
  }
}

@keyframes fade {
  from {
    transform: translateX(50px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* audio player */
#volume {
  -webkit-appearance: none;
  appearance: none;
  width: 110px;
  height: 7px;
  background: #414042;
  outline: none;
  border-radius: 50px;
}

#volume::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  background: #f1ede2;
  border-radius: 50%;
  cursor: pointer;
}

#volume::-moz-range-thumb {
  width: 20px;
  height: 20px;
  background: #f1ede2;
  border-radius: 50%;
  cursor: pointer;
}

#volume:hover {
  opacity: 1;
}

#album-cover {
  position: relative;
  animation: spin 4s linear infinite;
}

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

#album-cover {
  /* Add a white circle in the middle of the image */
  background: radial-gradient(circle, white, transparent);
  /* Center the circle within the image */
  background-position: center;
  /* Set the size of the circle to be slightly smaller than the image itself */
  background-size: calc(100% - 4px);
  /* Add some space around the image to make room for the circle */
  padding: 2px;
}

.img-wrapper::before {
  content: '';
  display: block;
  /* Set the size of the second circle to be 5px wide */
  width: 25%;
  z-index: 1;
  height: 25%;
  border-radius: 50%;
  background: rgb(0, 0, 0);
  /* Center the circle within the image */
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
