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

* {
margin: 0;
padding: 0;
box-sizing: border-box;
}

body {
 font-family: 'Manrope',sans-serif;
 font-size: 13px;
 background-color: hsl(210, 46%, 95%);
 display: flex;
 justify-content: center;
 min-height: 100vh;
 flex-direction: column;
 padding: 20px; /* Prevents content from touching screen edges */
}

main {
    display: flex;
    justify-content: center;
    align-items: center;
    flex: 1; /*makes <main> expand to fill leftover vertical space after the footer is placed*/
}

.container {
    max-width: 730px;
    width: 100%;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 40px 40px -10px rgba(201, 213, 225, 0.503415);
    display: flex;
    flex-direction: column;
    position: relative;
}

.drawers-image {
    width: 100%;
    height: 200px;
    object-fit: cover; /*make sure the image scales nicely*/
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
  }

.content {
    padding: 36px 32px 20px;
    flex: 1;
}

.content-title {
    font-size: 16px;
    line-height: 1.4;
    font-weight: 700;
    color: hsl(217, 19%, 35%);
    margin-bottom: 12px;
}

.content-caption {
    color: hsl(214, 17%, 51%);
    line-height: 1.5;
    margin-bottom: 32px;
}

.profile {
    display: flex;
    align-items: center;
    position: relative;
}

.profile-image {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 16px;
  }

  .profile-details {
    flex: 1
  }

.profile-name {
    line-height: 1.4;
    font-weight: 700;
    color: hsl(217, 19%, 35%);
    margin-bottom: 2px;
}

.profile-date {
    color: hsl(214, 17%, 51%);
    line-height: 1.5;
}

.share-btn {
    background-color: hsl(210, 46%, 95%);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
    z-index: 10;
}

.share-btn:hover {
    background-color: hsl(212, 23%, 69%);
  }
  
  .share-btn:hover img {
    filter: brightness(0) invert(1);
  }
  
  .share-btn.active {
    background-color: hsl(214, 17%, 51%);
  }
  
  .share-btn.active img {
    filter: brightness(0) invert(1);
  }

  .share-popup {
    display: none;
  }
  
  .share-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: hsl(217, 19%, 35%);
    padding: 22px 32px;
    display: flex;
    align-items: center;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    visibility: hidden;
    opacity: 0;
    z-index: 20;
  }

  .share-overlay.active {
    transform: translateY(0);
    transition: transform 0.3s ease;
    visibility: visible;
    opacity: 1;
  }

  .share-overlay .share-btn {
    background-color: hsl(214, 17%, 51%);
    z-index: 21;
  }
  
  .share-overlay .share-btn .share-icon {
    filter: brightness(0) invert(1);
  }

  .share-overlay span {
    color: hsl(212, 23%, 69%);
    letter-spacing: 5px;
  }

  .social-link {
    flex: 1;
    display: flex;
    justify-content: center;
    gap: 12px;
  }

  .social-icon {
    width: 20px;
    height: 20px;
    cursor: pointer;
    transition: transform 0.3s ease;
    filter: brightness(0) invert(1);
  }

  @media (min-width:769px) {
       .container {
        flex-direction: row;
       }

       .drawers-image {
        width: 285px;
        height: 100%;
        min-height: 280px;
        object-fit: cover; /*will scale to fill in and only slightly crop either top/bottom or sides but no stretcing*/
        object-position: left center;
        border-top-left-radius: 10px;
        border-bottom-left-radius: 10px;
        border-top-right-radius: 0px;
      }

      .content {
        padding: 32px 40px;
      }

      .content-title {
        font-size: 20px;
        margin-bottom: 12px;
      }
      
      .content-caption {
        margin-bottom: 20px;
      }

      .share-overlay {
        display: none;
      }

      .share-popup {
        position: absolute;
        background-color: hsl(217, 19%, 35%);
        border-radius: 10px;
        padding: 18px 36px;
        display: flex;
        align-items: center;
        top: -70px;
        right: -68px;
        gap: 16px;
        transform: translateY(10px);
      transition: all 0.3s ease;
      box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
      visibility: hidden;
      opacity: 0;
      }
    
      .share-popup::after {
        content: '';
        position: absolute;
        top: 100%;
        left: 60%;
        transform: translateX(-50%);
        border: 12px solid transparent;
        border-top-color: hsl(217, 19%, 35%); /*create the triangle shape*/
      }
    
    .share-popup.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
      }
    
      .share-popup span {
        color: hsl(212, 23%, 69%);
        letter-spacing: 5px;
      }
    
  }


.attribution { 
    font-size: 11px; 
    text-align: center; 
}

.attribution a { 
    color: hsl(228, 45%, 44%); 
}
