web/src/components/Hero.astro

145 lines · 3061 bytes

  1---
  2import FontAwesome from "@components/form/FontAwesome.svelte"
  3---
  4
  5<div class="hero">
  6  <h1>Awesome Privacy</h1>
  7  <p class="intro">
  8    Your guide to finding privacy-respecting alternatives to popular software and services.
  9  </p>
 10  <div class="github-link-wrap">
 11    <a href="https://github.com/lissy93/awesome-privacy">
 12      <FontAwesome iconName="github" />
 13      View on GitHub
 14    </a>
 15  </div>
 16</div>
 17
 18<nav class="top-right">
 19  <ul>
 20    <li>
 21      <a href="/">Home</a>
 22    </li>
 23    <li>
 24      <a href="/search">Search</a>
 25    </li>
 26    <li>
 27      <a href="/browse">Browse</a>
 28    </li>
 29    <li>
 30      <a href="/about">About</a>
 31    </li>
 32    <li>
 33      <a href="https://github.com/lissy93/awesome-privacy">Source</a>
 34    </li>
 35    <li>
 36      <a href="https://as93.net">More Apps</a>
 37    </li>
 38  </ul>
 39</nav>
 40
 41
 42<style lang="scss">
 43
 44	.hero {
 45    color: var(--accent-fg);
 46    border-radius: var(--curve-sm);
 47    padding: 2rem 4rem;
 48    display: flex;
 49    flex-direction: column;
 50    gap: 2rem;
 51	}
 52	svg {
 53		position: absolute;
 54		top: -32px;
 55		left: 50%;
 56		transform: translatex(-50%);
 57		width: 220px;
 58		height: auto;
 59		opacity: 0.6;
 60    display: none;
 61	}
 62	h1 {
 63    margin: 0;
 64		font-size: 5rem;
 65		font-weight: 700;
 66		line-height: 1;
 67		text-align: center;
 68    font-family: 'Libre Franklin', sans-serif;
 69    color: var(--accent-3);
 70    -webkit-text-fill-color: var(--accent-3);
 71    -webkit-text-stroke-width: 2px;
 72    -webkit-text-stroke-color: var(--foreground);
 73    text-shadow: 3px 3px 0 var(--foreground);
 74	}
 75  .intro {
 76    text-align: center;
 77    font-size: 1.6rem;
 78    padding: 0.5rem 1rem;
 79    color: var(--accent-fg);
 80    background: var(--accent-3);
 81    border: 2px solid var(--foreground);
 82    border-radius: var(--curve-sm);
 83    box-shadow: 6px 6px 0 var(--foreground);
 84    font-family: "Lekton", sans-serif;
 85    font-weight: 700;
 86    max-width: 735px;
 87    margin: 0 auto;
 88  }
 89  .github-link-wrap {
 90    font-family: "Lekton", sans-serif;
 91    max-width: 735px;
 92    text-align: center;
 93    margin: 0 auto;
 94    border: 1px solid var(--foreground);
 95    box-shadow: 3px 3px 0 var(--foreground);
 96    background: var(--accent);
 97    border-radius: 18px;
 98    padding: 0.5rem 1rem;
 99    a {
100      text-decoration: none;
101      color: var(--accent-fg);;
102      font-size: 1.2rem;
103      font-family: "Lekton", sans-serif;
104      font-weight: bold;
105      display: flex;
106      align-items: center;
107      :global(svg) {
108        width: 1.5rem;
109        height: 1.5rem;
110        color: var(--accent-fg);
111        margin-right: 0.5rem;
112      }
113    }
114  }
115
116  .top-right {
117    position: absolute;
118    top: 0;
119    right: 1rem;
120    opacity: 0.8;
121    display: none;
122    &:hover {
123      opacity: 1;
124    }
125    ul {
126      list-style: none;
127      display: flex;
128      padding: 0;
129      gap: 0.5rem;
130      li {
131        &:not(:last-child) {
132          border-right: 1px solid var(--accent);
133          padding-right: 0.5rem;
134        }
135      }
136      li a {
137        text-decoration: none;
138        &:hover {
139          text-decoration: underline;
140        }
141      }
142    }
143  }
144	
145</style>