File: resources/sass/card.scss

Recommend this page to a friend!
  Classes of Naif Alshaye  >  PHP World Clock  >  resources/sass/card.scss  >  Download  
File: resources/sass/card.scss
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: PHP World Clock
Display the time in different time zones
Author: By
Last change:
Date: 1 year ago
Size: 2,426 bytes
 

Contents

Class file image Download
body { height: 100% }

.analog-clock {
  top: 50%;
  right: 50%;
  width: 50vh;
  height: 50vh;
  position: absolute;
  border-radius: 100%;
  background-color: white;
  transform: translate3d(-1.5rem, -50%, 0);
  filter: drop-shadow(0 0.125rem 0.5rem rgba(black, 0.1));

  &::after {
    top: 50%;
    left: 50%;
    content: '';
    width: 2.5%;
    height: 2.5%;
    position: absolute;
    border-radius: 100%;
    background-color: #edbec5;
    transform: translate3d(-50%, -50%, 0);
  }

  &__face {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
  }

  &__notch {
    transform-origin: 50% 100%;
    position: absolute;
    width: 1px;
    height: 49%;
    bottom: 50%;
    left: 50%;

    &::after {
      content: '';
      width: 100%;
      height: 2.5%;
      position: absolute;
      top: 0;
      left: 0;
      background-color: #b6c3c9;
    }

    &.-long::after {
      width: 2px;
      height: 7.5%;
    }
  }

  &__hand {
    transform-origin: 50% 100%;
    background-color: #7392a0;
    position: absolute;
    width: 2px;
    height: 40%;
    bottom: 50%;
    left: 50%;
    border-radius: 2px;
    transition: transform 1s linear;

    &::after {
      content: '';
      position: absolute;
      top: 100%;
      left: 0;
      width: 100%;
      height: 10%;
      background-color: inherit;
      backface-visibility: hidden;
    }

    &.-hours {
      height: calc(100% / 3);
      width: 3px;
      border-radius: 3px;
      transition: transform 60s linear;
    }

    &.-seconds {
      width: 1px;
      height: 45%;
      border-radius: 0;
      background-color: #edbec5;
      transition: transform 100ms cubic-bezier(.6, .05, 0, 1.6);

      &::after {
        height: 12.5%;
      }
    }
  }
}

.text-clock {
  display: flex;
  top: 50%;
  left: 50%;
  font-size: 3rem;
  position: absolute;
  color: #99dcf9;
  transform: translate3d(1.5rem, -50%, 0);
  white-space: nowrap;

  &__col {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    text-align: center;
    line-height: 1.1;
    padding: 0.5rem 0.5rem 0.65rem;

    &.-meridiem {
      text-transform: uppercase;
      font-size: 0.85em;
      background-color: #7392a0;
      color: white;
      font-weight: 500;
      box-shadow: 0 0.25rem 0.75rem rgba(black, 0.1);
    }
  }

  &__row {
    flex: 1 0 0;
    display: flex;
    align-items: center;
  }
}

For more information send a message to info at phpclasses dot org.