/* =================================
   Florrid Projects - Shared Styles - v1.1.3
   ================================= */

/* Base styles */
* {
  box-sizing: border-box;
}

div {
  color: #292929;
}

h2 {
  margin: 0;
}

/* =================================
   Project Cards - Shared Components
   ================================= */

.card {
  background: #FFFFFF;
  border-radius: 16px;
  border: 1px solid rgba(54, 65, 64, 0.08);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
  overflow: hidden;
}

.card__header {
  position: relative;
}

.card__image {
  width: 100%;
  height: 292px;
  overflow: hidden;
  position: relative;
}

.card__image img {
  width: 100%;
  height: 100% !important;
  object-fit: cover;
  display: block;
}

.card__image-label {
  position: absolute;
  background: #1a1a1a;
  color: #FFFFFF;
  line-height: 24px;
  padding: 12px;
  font-size: 16px;
  font-weight: 500;
  top: 20px;
  left: 0;
  border-radius: 0 8px 8px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.card__label-flag {
  width: 24px;
  height: auto;
  display: inline-block;
  vertical-align: middle;
}

.card__body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: #FFFFFF;
}

.card__body-top {
  display: flex;
  flex-direction: column;
}

.card__body-bottom {
  display: flex;
  flex-direction: column;
}

.card__title {
  font-size: 24px;
  font-weight: 400;
  font-family: "BW Gradual", "Arial", sans-serif;
  color: #364140;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 28px;
  min-height: 56px;
}

.card__data-progress-flex {
  display: flex;
  width: 100%;
  justify-content: space-between;
}

.card__data-progress-flex-labels {
  display: flex;
  flex-direction: column;
}

.card__data-progress-flex-labels span:first-child {
  font-size: 16px;
  font-weight: 500;
  color: #364140;
}

.card__data-progress-flex-labels span:last-child {
  font-size: 14px;
  font-weight: 300;
  color: rgba(54, 65, 64, 0.64);
}

.card__data-progress-flex-labels:last-child {
  text-align: right;
}

.card__data-flex {
  display: flex;
  flex-direction: column;
  margin-top: 20px;
  gap: 20px;
}

.card__data-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px 24px;
  margin-top: 20px;
}

.card__data-progress-bar {
  width: 100%;
  height: 4px;
  background: #fceae8;
  position: relative;
  border-radius: 999px;
  overflow: hidden;
}

.card__data-progress-bar-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: #1a1a1a;
  border-radius: 999px;
}

.card__data-icon {
  flex-shrink: 0;
}

.card__data-icon-flex {
  display: inline-flex;
  position: relative;
  align-items: center;
  flex-direction: row;
  font-size: 14px;
  font-weight: 700;
  color: rgba(54, 65, 64, 0.64);
  gap: 8px;
}

.card__data-icon-flex .text {
  white-space: nowrap;
}

.card__data-icon-flex::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -12px;
  width: 1px;
  background: rgba(54, 65, 64, 0.3);
  display: block;
}

.card__data-icon-flex:nth-child(1)::before {
  display: none;
}

.card__button {
  margin-top: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  align-self: flex-end;
  padding: 16px 24px;
  background-color: transparent;
  border: 1px solid #FF6347;
  border-radius: 8px;
  font-family: "BW Gradual", "Arial", sans-serif;
  font-size: 14px;
  font-weight: 800;
  line-height: 24px;
  color: #FF6347;
}

.card__button:hover {
  border-color: #E5593F;
  color: #E5593F;
}

/* Tooltips */
.tooltip-container {
  position: relative;
}

.tooltip-container .tooltip {
  visibility: hidden;
  opacity: 0;
  background-color: rgba(41, 41, 41, 1);
  color: #fff;
  padding: 4px 8px;
  font-size: 14px;
  font-weight: 300;
  line-height: 20px;
  position: absolute;
  z-index: 100;
  bottom: calc(100% + 6px);
  left: 24px;
  margin-left: 0;
  white-space: nowrap;
  transition: opacity 0.3s;
}

.tooltip-container .tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 8px;
  border-width: 5px;
  border-style: solid;
  border-color: rgba(41, 41, 41, 1) transparent transparent transparent;
}

.tooltip-container:hover .tooltip {
  visibility: visible;
  opacity: 1;
}

/* Coming Soon Card */
.card.coming-soon-card {
  position: relative;
  overflow: hidden;
  cursor: default;
  pointer-events: none;
  background: #FBE9E6;
  border: none;
  box-shadow: none;
}

.coming-soon-card .card-link-wrapper {
  pointer-events: none;
  cursor: default;
}

.coming-soon-card__content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 341px;
  max-width: calc(100% - 48px);
  z-index: 2;
}

.coming-soon-card__icon {
  width: 72px;
  height: 72px;
  background: #FFFFFF;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.coming-soon-card__icon svg {
  width: 40px;
  height: 40px;
  display: block;
}

.coming-soon-card__title {
  font-family: "BW Gradual", "Arial", sans-serif;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.24px;
  color: #292929;
  text-align: center;
  width: 100%;
  margin: 56px 0 0;
}

.coming-soon-card__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 40px;
  padding: 14px 28px;
  background: #FFFFFF;
  border: 1px solid #FF6347;
  border-radius: 999px;
  color: #FF6347 !important;
  font-family: "BW Gradual", "Arial", sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  text-decoration: none;
  pointer-events: auto;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.coming-soon-card__button:hover {
  background: #FF6347;
  color: #FFFFFF !important;
}

.coming-soon-card__border {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px dashed #9E9DA8;
  border-radius: 24px;
  pointer-events: none;
  z-index: 3;
}

/* Show All Button */
#show-all-button {
  background-color: transparent;
  border-color: var(--main-light);
  color: var(--main-light);
  margin-top: 52px;
}

#show-all-button:hover {
  border-color: #FFD06B;
  color: #FFD06B;
}

/* =================================
   Homepage Cards - grid copied from the investment portal:
   .florrid-container (max-width 1440, padding 0 120px)
   + .investment-card-wrappers (3 columns, gap 15px)
   ================================= */

#js-api-home-cards.card-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  width: 100%;
  max-width: 1440px;
  margin: 0 auto 40px;
  padding: 0 120px;
  box-sizing: border-box;
}

/* Coming-soon card has absolutely positioned content, so it needs
   a height of its own in case it ends up alone in a row */
#js-api-home-cards .card.coming-soon-card {
  min-height: 560px;
}

/* Portal breakpoints */
@media (max-width: 1200px) {
  #js-api-home-cards.card-container {
    padding: 0 40px;
  }
}

@media (max-width: 992px) {
  #js-api-home-cards.card-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 744px) {
  #js-api-home-cards.card-container {
    padding: 0 20px;
  }
}

@media (max-width: 575px) {
  #js-api-home-cards.card-container {
    grid-template-columns: repeat(1, 1fr);
  }
}

/* =================================
   Grid Container (Non-scrollable)
   ================================= */

#js-api-cards-block.card-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
  justify-content: center;
  width: 100%;
  max-width: 1199px;
}

#js-api-cards-block .card {
  width: 100%;
}

/* =================================
   Single Project Page
   ================================= */

.featured-card {
  align-self: stretch;
  margin-bottom: 40px;
  border-radius: 16px;
  overflow: hidden;
}

.content-wrapper {
  display: flex;
  border-radius: 24px;
  overflow: hidden;
  background: #FFFFFF;
  border: 1px solid #36414029;
  box-shadow: 0px 4px 8px 0px rgba(0, 0, 0, 0.04);
}

.image-column {
  display: flex;
  flex-direction: column;
  width: 57%;
  position: relative;
  aspect-ratio: 1 / 1.1;
}

.image-container {
  display: flex;
  flex-direction: column;
  position: relative;
  width: 100%;
  height: 100%;
}

.project-image {
  display: block;
  height: 100% !important;
  width: 100%;
  object-fit: cover;
}

.status-badge {
  position: absolute;
  background: #1a1a1a;
  color: #FFFFFF;
  padding: 12px;
  top: 20px;
  font: 500 16px "BW Gradual", "Arial", sans-serif;
  left: 0;
  border-radius: 0 8px 8px 0;
}

.image-navigation {
  position: absolute;
  align-self: end;
  display: flex;
  align-items: center;
  gap: 16px;
  right: 20px;
  bottom: 20px;
}

.nav-button {
  aspect-ratio: 1;
  object-fit: contain;
  width: 56px;
  cursor: pointer;
}

.nav-button:hover {
  filter: brightness(0) saturate(100%) invert(80%) sepia(38%) saturate(751%) hue-rotate(332deg) brightness(103%) contrast(101%);
}

.details-column {
  display: flex;
  flex-direction: column;
  width: 43%;
}

.details-card {
  background-color: #FFFFFF;
  display: flex;
  min-height: 629px;
  flex-grow: 1;
  gap: 8px;
  width: 100%;
  padding: 32px;
}

.card-content {
  display: flex;
  min-width: 240px;
  width: 100%;
  flex-direction: column;
  justify-content: space-between;
  flex: 1;
}

.project-header {
  display: flex;
  width: 100%;
  flex-direction: column;
}

.project-title {
  color: var(--Dark, #292929);
  letter-spacing: -0.32px;
  font: 400 32px/1 BW Gradual", "Arial, sans-serif;
}

.project-address {
  color: var(--Shadow, #58575d);
  margin-top: 12px;
  font: 300 16px "BW Gradual", "Arial", sans-serif;
}

.project-stats {
  display: flex;
  margin-top: 105px;
  width: 100%;
  flex-direction: column;
}

.stats-container {
  display: flex;
  width: 100%;
  flex-direction: column;
  color: var(--Dark, #292929);
}

.stats-row {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
}

.stat-item {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.stat-label {
  font: 300 14px/1 "BW Gradual", "Arial", sans-serif;
}

.stat-value {
  margin-top: 4px;
  letter-spacing: -0.32px;
  font: 400 32px/1 BW Gradual", "Arial, sans-serif;
}

.progress-section {
  display: flex;
  margin-top: 56px;
  width: 100%;
  align-items: start;
  gap: 20px;
  font-family: "BW Gradual", "Arial", sans-serif;
}

.progress-item {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.progress-value {
  font-size: 16px;
  font-weight: 500;
}

.progress-label {
  font-size: 14px;
  font-weight: 300;
  line-height: 1;
  margin-top: 4px;
}

.progress-bar {
  background: #fceae8;
  margin-top: 20px;
  width: 100%;
  overflow: hidden;
  border-radius: 999px;
}

.progress-fill {
  background: #1a1a1a;
  height: 4px;
  border-radius: 999px;
}

.invest-button {
  border-radius: 10px;
  background: #FF6347 !important;
  background-color: #FF6347 !important;
  margin-top: 40px;
  width: 100%;
  color: #FFFFFF !important;
  text-align: center;
  padding: 16px 70px;
  font: 500 16px "BW Gradual", "Arial", sans-serif;
  cursor: pointer;
  border: none;
}

a .invest-button,
button.invest-button {
  color: #FFFFFF !important;
  background: #FF6347 !important;
  background-color: #FF6347 !important;
}

.invest-button--disabled,
.invest-button:disabled {
  background: #ECECEC !important;
  background-color: #ECECEC !important;
  color: #9E9DA8 !important;
  cursor: not-allowed;
}

#investor-comment-section {
  display: none;
}

/* Parameters Section */
.parameters-container__wrapper {
  background-color: #FFFFFF;
  display: flex;
  flex-direction: column;
  padding: 40px;
  gap: 32px;
  margin-top: 40px;
  align-items: center;
  border-radius: 24px;
  border: 1px solid #36414029;
  box-shadow: 0px 4px 8px 0px rgba(0, 0, 0, 0.04);
}

.parameters-container {
  display: flex;
  background: #FFFFFF;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: flex-start;
}

.parameter-item {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-height: 200px;
  opacity: 1;
  overflow: hidden;
  transition: max-height 0.3s ease-in-out, opacity 0.3s ease-in-out;
}

.parameter-item.hidden {
  max-height: 0;
  opacity: 0;
}

.param-icon {
  width: 56px;
  height: 56px;
  margin-bottom: 16px;
  object-fit: contain;
}

.param-title {
  font-size: 24px;
  line-height: 24px;
  font-weight: 400;
  margin-bottom: 12px;
  color: #292929;
}

.param-description {
  font-size: 14px;
  font-weight: 300;
  color: #292929;
}

.show-more-btn {
  padding: 16px 36px;
  background-color: transparent !important;
  border: 1px solid #292929 !important;
  border-radius: 10px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
}

/* Project Information Blocks */
.info-blocks {
  background-color: #FFFFFF;
  display: flex;
  flex-direction: column;
  gap: 40px;
  padding: 40px;
  margin-top: 40px;
  border-radius: 24px;
  border: 1px solid #36414029;
  box-shadow: 0px 4px 8px 0px rgba(0, 0, 0, 0.04);
}

.info-block__title {
  color: #292929;
  letter-spacing: -0.32px;
  font: 400 32px/1.1 "BW Gradual", "Arial", sans-serif;
  margin: 0 0 20px;
}

.info-block__content {
  color: #292929;
  font-size: 16px;
  font-weight: 300;
  line-height: 1.5;
}

.info-block__content p {
  margin: 0 0 12px;
}

.info-block__content p:last-child {
  margin-bottom: 0;
}

.info-block__content img {
  max-width: 100%;
  height: auto;
}

.project-disclaimer .info-block__content {
  font-size: 18px;
}

.project-disclaimer__link {
  color: #FF6347 !important;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.project-disclaimer__link:hover {
  color: #e5533a !important;
}

/* =================================
   Media Queries
   ================================= */

/* Desktop */
@media (min-width: 1201px) {
  .card__data-icon-flex.tooltip-container:nth-child(3n) .tooltip {
    bottom: calc(100% + 6px);
    left: auto;
    right: -34px;
    transform: none;
  }

  .card__data-icon-flex.tooltip-container:nth-child(3n) .tooltip::after {
    top: 100%;
    left: auto;
    right: 16px;
  }

  .parameter-item {
    width: calc((100% - 32px * 4) / 5);
  }

  .parameters-container {
    width: 100%;
    justify-content: flex-start;
  }
}

/* Tablet & Mobile */
@media (max-width: 1200px) {
  #js-api-home-cards .card {
    border-radius: 8px;
  }

  .card {
    border-radius: 8px;
  }

  .coming-soon-card__border {
    border-radius: 8px;
  }

  /* Single project adjustments */
  .content-wrapper {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .image-column {
    aspect-ratio: 1.38/1;
    width: 100%;
  }

  .details-column {
    width: 100%;
  }

  .details-card {
    min-height: auto;
  }

  .project-stats {
    margin-top: 40px;
  }

  .progress-section {
    margin-top: 40px;
  }

  .invest-button {
    padding: 0 20px;
  }

  .featured-card {
    display: none;
  }

  .parameters-container {
    justify-content: center;
  }

  .info-blocks {
    padding: 24px;
    gap: 32px;
    border-radius: 8px;
  }

  .info-block__title {
    font-size: 24px;
  }
}

/* Tablet */
@media (min-width: 744px) and (max-width: 1200px) {
  .parameter-item {
    width: calc((100% - 32px * 2) / 3);
  }
}

/* Mobile */
@media (max-width: 743px) {
  .parameter-item {
    width: calc((100% - 32px) / 2);
  }

  .parameters-container {
    justify-content: center;
  }
}
