@charset "UTF-8";
@import url('https://assets.mentalista.fr/font/?family=mentalista-grotesque,ibm-plex-sans,ibm-plex-mono');

:root{

  /* GENERAL */
  --theme-background-color: rgba(0,0,0);
  --theme-color:            rgba(255,255,255);
  --theme-font-family:      'IBM Plex Mono';

  /* HEADER */
  --header-padding:         30px;
  --header-font-size:       20px;

  /* COLLECTION */
  --collection-padding:     15px;
  --collection-margin-top:  300px;

  /* EXPERIENCE */
  --experience-width:       550px;
}


/* ––––––––––––––––––––––––
         LIGHT MODE
–––––––––––––––––––––––– */

[data-theme="light"] {
  --theme-background-color: rgba(238,238,238);
  --theme-color: rgba(0,0,0);
}

/* ––––––––––––––––––––––––
          GLOBAL
–––––––––––––––––––––––– */

*{
  margin:0;padding:0;
  font-family: var(--theme-font-family);
  list-style: none;
}

/* Works on Chrome, Edge, and Safari */
*::-webkit-scrollbar {
  width: 5px;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  background-color: #333;
  border-radius: 20px;
}

body {
  background: var(--theme-background-color);
  overflow-x: hidden;
}

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

/* ––––––––––––––––––––––––
          HEADER
–––––––––––––––––––––––– */

header {
  position: fixed;
  z-index: 9;
  top:0; left: 0;
  width: calc(100% - calc(var(--header-padding) * 2));
  display: flex;
  padding: var(--header-padding);
}

header p {
  color: var(--theme-color);
  font-size: var(--header-font-size);
}

header p:last-child{
  margin-left: auto;
  text-align: end;
}

.italic{
  font-style: italic;
}

/* ––––––––––––––––––––––––
         COLLECTION
–––––––––––––––––––––––– */

section {
  margin-top: var(--collection-margin-top);
}

#collection {
  padding:var(--collection-padding);
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* ACCENTURE = 3 */
  grid-gap: var(--collection-padding);
  width: calc(100% - calc(var(--collection-padding) * 2));
}

/* ––––––––––––––––––––––––
       COLLECTION.ITEM
–––––––––––––––––––––––– */

#collection .item img {
  width: 100%;
}

#collection .item {
  -webkit-animation: fadeIn 2s;
     -moz-animation: fadeIn 2s;
      -ms-animation: fadeIn 2s;
       -o-animation: fadeIn 2s;
          animation: fadeIn 2s;
}

.frame {  
  position: relative;
  border-width:15px;
  border-image:      url(../assets/img/wood-frame.jpg) 30 30 stretch;
  -moz-border-image: url(../assets/img/wood-frame.jpg) 30 30 stretch;
  -ms-border-image:  url(../assets/img/wood-frame.jpg) 30 30 stretch;
  -o-border-image:   url(../assets/img/wood-frame.jpg) 30 30 stretch;
  border-style:solid;
  aspect-ratio : 1/1;
}

#collection .item.frame a {  
  position: absolute;
  width: 100%;
  height: 100%;
}

@keyframes fadeIn {
  0% {opacity:0;}
  100% {opacity:1;}
}

/* ––––––––––––––––––––––––
         POP-UP
–––––––––––––––––––––––– */

.popup {
  position: fixed;
  top:50%;left:50%;
  transform: translate(-50%,-50%);
  width:300px;
  height: 200px;

  border-radius: 15px;
  background-color: #333;
  padding:30px;
}

.popup p {
  margin-top: 15px;
}

.popup button {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  width:50px;
  cursor: pointer;
}

/* ––––––––––––––––––––––––
         ARTWORK
–––––––––––––––––––––––– */

#mental-plant {
  
  position: absolute;

  width:  600px;
  height: 600px;

  top: 50%; left: 50%;
  transform: translate(-50%,-50%);

  background-color: #111;
}

/* ––––––––––––––––––––––––
        EXPERIENCE
–––––––––––––––––––––––– */

#experience {
  
  position: absolute;

  width:  var(--experience-width);
  height: var(--experience-width);

  top: 50%; left: 50%;
  transform: translate(-50%,-50%);

  background-color: var(--controls-btn-background);
}

#experience canvas{
  width:  100%;
  height: 100%;

  max-width:  var(--experience-width);
  max-height: var(--experience-width);
}

/* ––––––––––––––––––––––– */

@media screen and (max-width: 690px) {
  
  #collection {
    grid-template-columns: repeat(1, 1fr);
  }

  #mental-plant {
    width: 80%;
    height: auto;
  }
}


